diff --git a/.github/workflows/container-build.yml b/.github/workflows/container-build.yml new file mode 100644 index 0000000000..b68da9a0ee --- /dev/null +++ b/.github/workflows/container-build.yml @@ -0,0 +1,45 @@ +name: container build +on: + push: + tags: + - '**' + branches: + - '**' + - '!master' + schedule: + - cron: '0 0 * * *' +jobs: + container-build: + runs-on: ubuntu-latest + steps: + - name: checkout + uses: actions/checkout@v3 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + - name: Log into registry + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Docker meta + id: meta + uses: docker/metadata-action@v5 + with: + images: commitlint/commitlint + tags: | + type=semver,pattern={{version}} + type=edge,branch=master + type=ref,event=branch + type=sha,prefix=,format=short + - name: Build and push container image + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ci + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + # disable arm build for now, because of https://github.com/nodejs/docker-node/issues/1335 + platforms: linux/amd64 #,linux/arm64 diff --git a/@alias/commitlint/CHANGELOG.md b/@alias/commitlint/CHANGELOG.md index 61c87e11f5..32e7d64347 100644 --- a/@alias/commitlint/CHANGELOG.md +++ b/@alias/commitlint/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package commitlint + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package commitlint diff --git a/@alias/commitlint/package.json b/@alias/commitlint/package.json index 8830c68828..62e5194fba 100644 --- a/@alias/commitlint/package.json +++ b/@alias/commitlint/package.json @@ -1,6 +1,6 @@ { "name": "commitlint", - "version": "17.7.1", + "version": "17.7.2", "description": "Lint your commit messages", "files": [ "cli.js" @@ -35,7 +35,7 @@ }, "license": "MIT", "dependencies": { - "@commitlint/cli": "^17.7.1", + "@commitlint/cli": "^17.7.2", "@commitlint/types": "^17.4.4" }, "devDependencies": { diff --git a/@commitlint/cli/CHANGELOG.md b/@commitlint/cli/CHANGELOG.md index ff5b2ed5be..031be977d7 100644 --- a/@commitlint/cli/CHANGELOG.md +++ b/@commitlint/cli/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package @commitlint/cli + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package @commitlint/cli diff --git a/@commitlint/cli/package.json b/@commitlint/cli/package.json index 638714a1e7..e33b91e3e5 100644 --- a/@commitlint/cli/package.json +++ b/@commitlint/cli/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/cli", - "version": "17.7.1", + "version": "17.7.2", "description": "Lint your commit messages", "files": [ "index.js", @@ -49,7 +49,7 @@ "dependencies": { "@commitlint/format": "^17.4.4", "@commitlint/lint": "^17.7.0", - "@commitlint/load": "^17.7.1", + "@commitlint/load": "^17.7.2", "@commitlint/read": "^17.5.1", "@commitlint/types": "^17.4.4", "execa": "^5.0.0", diff --git a/@commitlint/core/CHANGELOG.md b/@commitlint/core/CHANGELOG.md index 94c9caee8c..08f55c3e67 100644 --- a/@commitlint/core/CHANGELOG.md +++ b/@commitlint/core/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package @commitlint/core + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package @commitlint/core diff --git a/@commitlint/core/package.json b/@commitlint/core/package.json index f393856de7..decbb8fc59 100644 --- a/@commitlint/core/package.json +++ b/@commitlint/core/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/core", - "version": "17.7.1", + "version": "17.7.2", "description": "Lint your commit messages", "main": "lib/core.js", "types": "lib/core.d.ts", @@ -37,7 +37,7 @@ "dependencies": { "@commitlint/format": "^17.4.4", "@commitlint/lint": "^17.7.0", - "@commitlint/load": "^17.7.1", + "@commitlint/load": "^17.7.2", "@commitlint/read": "^17.5.1" }, "devDependencies": { diff --git a/@commitlint/cz-commitlint/CHANGELOG.md b/@commitlint/cz-commitlint/CHANGELOG.md index 26a8a045b1..086454f551 100644 --- a/@commitlint/cz-commitlint/CHANGELOG.md +++ b/@commitlint/cz-commitlint/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package @commitlint/cz-commitlint + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package @commitlint/cz-commitlint diff --git a/@commitlint/cz-commitlint/package.json b/@commitlint/cz-commitlint/package.json index 6355e5e52f..1e13c81aeb 100644 --- a/@commitlint/cz-commitlint/package.json +++ b/@commitlint/cz-commitlint/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/cz-commitlint", - "version": "17.7.1", + "version": "17.7.2", "description": "Commitizen adapter using the commitlint.config.js", "main": "./lib/index.js", "files": [ @@ -38,7 +38,7 @@ }, "dependencies": { "@commitlint/ensure": "^17.6.7", - "@commitlint/load": "^17.7.1", + "@commitlint/load": "^17.7.2", "@commitlint/types": "^17.4.4", "chalk": "^4.1.0", "lodash.isplainobject": "^4.0.6", diff --git a/@commitlint/load/CHANGELOG.md b/@commitlint/load/CHANGELOG.md index 3ea4191dd3..92541a3a3a 100644 --- a/@commitlint/load/CHANGELOG.md +++ b/@commitlint/load/CHANGELOG.md @@ -3,6 +3,17 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + + +### Bug Fixes + +* update dependency @types/node to v20.5.1 ([#3653](https://github.com/conventional-changelog/commitlint/issues/3653)) ([cd8b775](https://github.com/conventional-changelog/commitlint/commit/cd8b7750d3a15fbfd96e20196d53df064df6e138)) + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) diff --git a/@commitlint/load/package.json b/@commitlint/load/package.json index c3c3f5d399..df66e537b1 100644 --- a/@commitlint/load/package.json +++ b/@commitlint/load/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/load", - "version": "17.7.1", + "version": "17.7.2", "description": "Load shared commitlint configuration", "main": "lib/load.js", "types": "lib/load.d.ts", diff --git a/@commitlint/prompt-cli/CHANGELOG.md b/@commitlint/prompt-cli/CHANGELOG.md index cc489afa05..7eac3371c1 100644 --- a/@commitlint/prompt-cli/CHANGELOG.md +++ b/@commitlint/prompt-cli/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package @commitlint/prompt-cli + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package @commitlint/prompt-cli diff --git a/@commitlint/prompt-cli/package.json b/@commitlint/prompt-cli/package.json index bd3abc76d0..83391e693d 100644 --- a/@commitlint/prompt-cli/package.json +++ b/@commitlint/prompt-cli/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/prompt-cli", - "version": "17.7.1", + "version": "17.7.2", "description": "commit prompt using commitlint.config.js", "files": [ "cli.js" @@ -36,7 +36,7 @@ "@commitlint/utils": "^17.4.0" }, "dependencies": { - "@commitlint/prompt": "^17.7.1", + "@commitlint/prompt": "^17.7.2", "execa": "^5.0.0", "inquirer": "^6.5.2" }, diff --git a/@commitlint/prompt/CHANGELOG.md b/@commitlint/prompt/CHANGELOG.md index 3a0e13b5a6..be98e2fee8 100644 --- a/@commitlint/prompt/CHANGELOG.md +++ b/@commitlint/prompt/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package @commitlint/prompt + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package @commitlint/prompt diff --git a/@commitlint/prompt/package.json b/@commitlint/prompt/package.json index 4a4245c604..3465651311 100644 --- a/@commitlint/prompt/package.json +++ b/@commitlint/prompt/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/prompt", - "version": "17.7.1", + "version": "17.7.2", "description": "commitizen prompt using commitlint.config.js", "main": "./lib/index.js", "files": [ @@ -46,7 +46,7 @@ }, "dependencies": { "@commitlint/ensure": "^17.6.7", - "@commitlint/load": "^17.7.1", + "@commitlint/load": "^17.7.2", "@commitlint/types": "^17.4.4", "chalk": "^4.1.0", "inquirer": "^6.5.2" diff --git a/@commitlint/travis-cli/CHANGELOG.md b/@commitlint/travis-cli/CHANGELOG.md index 68fa738483..4b62d3c09d 100644 --- a/@commitlint/travis-cli/CHANGELOG.md +++ b/@commitlint/travis-cli/CHANGELOG.md @@ -3,6 +3,14 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + +**Note:** Version bump only for package @commitlint/travis-cli + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) **Note:** Version bump only for package @commitlint/travis-cli diff --git a/@commitlint/travis-cli/package.json b/@commitlint/travis-cli/package.json index 4462b3efbc..d9dcae5e2b 100644 --- a/@commitlint/travis-cli/package.json +++ b/@commitlint/travis-cli/package.json @@ -1,6 +1,6 @@ { "name": "@commitlint/travis-cli", - "version": "17.7.1", + "version": "17.7.2", "description": "Lint all relevant commits for a change or PR on Travis CI", "files": [ "lib/", @@ -40,7 +40,7 @@ "@commitlint/utils": "^17.4.0" }, "dependencies": { - "@commitlint/cli": "^17.7.1", + "@commitlint/cli": "^17.7.2", "execa": "^5.0.0" }, "gitHead": "70f7f4688b51774e7ac5e40e896cdaa3f132b2bc" diff --git a/CHANGELOG.md b/CHANGELOG.md index 6899a366af..1d1a1784f2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,17 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [17.7.2](https://github.com/conventional-changelog/commitlint/compare/v17.7.1...v17.7.2) (2023-09-28) + + +### Bug Fixes + +* update dependency @types/node to v20.5.1 ([#3653](https://github.com/conventional-changelog/commitlint/issues/3653)) ([cd8b775](https://github.com/conventional-changelog/commitlint/commit/cd8b7750d3a15fbfd96e20196d53df064df6e138)) + + + + + ## [17.7.1](https://github.com/conventional-changelog/commitlint/compare/v17.7.0...v17.7.1) (2023-08-10) diff --git a/Dockerfile.ci b/Dockerfile.ci new file mode 100644 index 0000000000..babe60d0db --- /dev/null +++ b/Dockerfile.ci @@ -0,0 +1,30 @@ +FROM docker.io/library/node:18-buster AS builder +WORKDIR /src +COPY . ./ +RUN yarn install && \ + yarn run build && \ + # Commit lint CLI packages + npm pack @commitlint/cli && \ + npm pack @commitlint/config-validator && \ + npm pack @commitlint/ensure && \ + npm pack @commitlint/execute-rule && \ + npm pack @commitlint/format && \ + npm pack @commitlint/is-ignored && \ + npm pack @commitlint/lint && \ + npm pack @commitlint/load && \ + npm pack @commitlint/message && \ + npm pack @commitlint/parse && \ + npm pack @commitlint/read && \ + npm pack @commitlint/resolve-extends && \ + npm pack @commitlint/rules && \ + npm pack @commitlint/to-lines && \ + npm pack @commitlint/top-level && \ + npm pack @commitlint/types && \ + # Default commitlint config + npm pack @commitlint/config-conventional + +FROM docker.io/library/node:18-buster +COPY --from=builder /src/*.tgz ./ +RUN npm install -g *.tgz && \ + rm -rf *.tgz +ENTRYPOINT ["commitlint"] diff --git a/Dockerfile b/Dockerfile.dev similarity index 100% rename from Dockerfile rename to Dockerfile.dev diff --git a/docker-compose.yml b/docker-compose.yml index 5e57122d7a..401320c97e 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,7 +1,9 @@ version: '3' services: commitlint: - build: . + build: + context: . + dockerfile: Dockerfile.dev image: marionebl/commitlint-cubicle ports: - '8443:8443' diff --git a/docs/guides-ci-setup.md b/docs/guides-ci-setup.md index 6b3ed628c6..870fa924ab 100644 --- a/docs/guides-ci-setup.md +++ b/docs/guides-ci-setup.md @@ -121,12 +121,30 @@ workflows: ## GitLab CI ```yaml +stages: ["lint","build","test"] lint:commit: + image: registry.hub.docker.com/library/node:alpine stage: lint + before_script: + - apk add --no-cache git + - npm install --save-dev @commitlint/config-conventional @commitlint/cli script: - echo "${CI_COMMIT_MESSAGE}" | npx commitlint ``` +## GitLab CI with pre-build container + +```yaml +stages: ["lint","build","test"] +lint:commit: + image: + name: registry.hub.docker.com/commitlint/commitlint:latest + entrypoint: [""] + stage: lint + script: + - echo "${CI_COMMIT_MESSAGE}" | commitlint +``` + ### 3rd party integrations #### [Codemagic](https://codemagic.io/) diff --git a/lerna.json b/lerna.json index 3a0814b797..9d3e410656 100644 --- a/lerna.json +++ b/lerna.json @@ -2,5 +2,5 @@ "lerna": "4", "npmClient": "yarn", "useWorkspaces": true, - "version": "17.7.1" + "version": "17.7.2" }