From a58862e54075dfd9b51b99ba3b1f5e8837294ef2 Mon Sep 17 00:00:00 2001 From: ssube Date: Mon, 23 Sep 2019 08:13:44 -0500 Subject: [PATCH] lint: quote paths, ignore changelog --- .codeclimate.yml | 1 + README.md | 24 ++++++++++++++---------- config/rollup-named.json | 3 ++- scripts/ci-project-path.sh | 2 +- scripts/docker-build.sh | 4 ++-- scripts/project-create.sh | 4 ++-- 6 files changed, 22 insertions(+), 16 deletions(-) diff --git a/.codeclimate.yml b/.codeclimate.yml index 8e1fc03..c2f8996 100644 --- a/.codeclimate.yml +++ b/.codeclimate.yml @@ -1,6 +1,7 @@ version: "2" exclude_patterns: + - CHANGELOG.md - docs/api/ - src/migration/ - vendor/ diff --git a/README.md b/README.md index 041dac7..cda7624 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # Rollup Template -This project contains the base configuration and build scripts for most of my Typescript/Rollup projects. +This project contains the base configuration and build scripts for most of +my Typescript projects, along with scripts to createe a new project. [![Pipeline status](https://img.shields.io/gitlab/pipeline/ssube/rollup-template.svg?gitlab_url=https%3A%2F%2Fgit.apextoaster.com&logo=gitlab)](https://git.apextoaster.com/ssube/rollup-template/commits/master) [![MIT license](https://img.shields.io/github/license/ssube/rollup-template.svg)](https://github.com/ssube/rollup-template/blob/master/LICENSE.md) @@ -73,7 +74,8 @@ Once your project is set up: - commit - `make git-push` -The `git-push` target pushes to Github first, to avoid conflicts with changes from bots and other contributors. +The `git-push` target pushes to Github first, to avoid conflicts with changes from bots and +other contributors. ### To Release @@ -82,18 +84,18 @@ When your project is ready to release: - `make release-dry` to make sure your changelog and options look right - `make release` -Additional options can be passed with the `RELEASE_OPTS` variable. Frequently-used options include `--release-as minor` -and `--prerelease`. +Additional options can be passed with the `RELEASE_OPTS` variable. Frequently-used options +include `--release-as minor` and `--prerelease`. ## External Services -This template works with or expects a few external services, namely a Gitlab CI server (self-hosted or using -Gitlab.com). +This template works with or expects a few external services, namely a Gitlab CI server +(self-hosted or using Gitlab.com). ### Maintenance Bots -Good tests and clever bots can eliminate the most painful parts of project maintenance. This repository is -configured to work with: +Good tests and clever bots can eliminate the most painful parts of project maintenance. This +repository is configured to work with: - [CodeCov](https://codecov.io/) - [Code Climate](https://codeclimate.com/) @@ -102,11 +104,13 @@ configured to work with: - [Snyk](https://snyk.io/) - [SonarCloud](https://sonarcloud.io/) -None of these are required, but Renovate and Snyk can be very helpful when dependencies release a security patch. +None of these are required, but Renovate and Snyk can be very helpful when dependencies release +a security patch (and even more so when they decline). ## External Secrets -This template expects a few secrets to exist in the environment, including tokens for the [external services](#external-services). +This template expects a few secrets to exist in the environment, including tokens for +the [external services](#external-services). | Name | Description | | ------------------- | ----------------------------------------------------- | diff --git a/config/rollup-named.json b/config/rollup-named.json index b69d086..b31da20 100644 --- a/config/rollup-named.json +++ b/config/rollup-named.json @@ -1,5 +1,6 @@ { "node_modules/chai/index.js": [ - "expect" + "expect", + "use" ] } \ No newline at end of file diff --git a/scripts/ci-project-path.sh b/scripts/ci-project-path.sh index 7fb22c0..f941420 100755 --- a/scripts/ci-project-path.sh +++ b/scripts/ci-project-path.sh @@ -2,6 +2,6 @@ PROJECT="${ROOT_PATH}" PARENT="$(dirname "${PROJECT}")" -PROJECT_PATH="$(basename ${PARENT})/$(basename ${PROJECT})" +PROJECT_PATH="$(basename "${PARENT}")/$(basename "${PROJECT}")" echo "${PROJECT_PATH}" \ No newline at end of file diff --git a/scripts/docker-build.sh b/scripts/docker-build.sh index 8757261..849986f 100755 --- a/scripts/docker-build.sh +++ b/scripts/docker-build.sh @@ -8,10 +8,10 @@ IMAGE_FULL="${IMAGE_NAME}:${IMAGE_TAG}" echo "Building image: ${IMAGE_FULL}" -docker build -t ${IMAGE_FULL} . +docker build -t "${IMAGE_FULL}" . if [[ "${IMAGE_PUSH}" == "--push" ]]; then echo "Pushing image: ${IMAGE_FULL}" - docker push ${IMAGE_FULL} + docker push "${IMAGE_FULL}" fi diff --git a/scripts/project-create.sh b/scripts/project-create.sh index 4b69e10..4c700c3 100755 --- a/scripts/project-create.sh +++ b/scripts/project-create.sh @@ -9,8 +9,8 @@ pushd ../"${PROJECT_NAME}" echo "Setting up repository..." git init -git remote add github git@github.com:${PROJECT_PATH}/${PROJECT_NAME}.git -git remote add gitlab git@git.apextoaster.com:${PROJECT_PATH}/${PROJECT_NAME}.git +git remote add github "git@github.com:${PROJECT_PATH}/${PROJECT_NAME}.git" +git remote add gitlab "git@git.apextoaster.com:${PROJECT_PATH}/${PROJECT_NAME}.git" echo "Setting up template..." popd