Skip to content

Commit

Permalink
fix: changescribe
Browse files Browse the repository at this point in the history
  • Loading branch information
gbertoncelli committed Feb 22, 2024
1 parent 86ca254 commit 9657b38
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 14 deletions.
6 changes: 6 additions & 0 deletions .changescriberc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"generate": {
"fromPackageJson": true,
"taskUrlTemplate": "https://ctinnovation.atlassian.net/browse/{taskCode}"
}
}
2 changes: 1 addition & 1 deletion .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module.exports = {
env: {
browser: true,
browser: false,
commonjs: true,
es2021: true
},
Expand Down
21 changes: 11 additions & 10 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,14 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
with:
token: ${{ secrets.REPO_ACCESS }}

- name: Setup Node.js environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
registry-url: https://npm.pkg.github.com/
scope: "@ctinnovation"

- name: install dependencies
run: npm install -g @ctinnovation/changelogger
run: npm install -g changescribe
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_GET_TOKEN}}

Expand All @@ -54,7 +50,7 @@ jobs:
- name: Create pull request
id: pr-create
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ github.token }}
script: |
Expand All @@ -70,7 +66,7 @@ jobs:
return res.data.number;
- name: Request and assign review
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ github.token }}
script: |
Expand Down Expand Up @@ -99,8 +95,6 @@ jobs:
- name: Checkout
if: "${{ env.TAG }}"
uses: actions/checkout@v4
with:
token: ${{ secrets.REPO_ACCESS }}

- name: Tagging
if: "${{ env.TAG }}"
Expand All @@ -110,7 +104,7 @@ jobs:
- name: Create and publish release on tag
if: "${{ env.TAG }}"
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ github.token }}
script: |
Expand All @@ -122,6 +116,13 @@ jobs:
name: "${{ env.TAG }}"
})
- name: Setup Node.js environment
uses: actions/setup-node@v4
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
always-auth: "true"

- name: NPM package publish
if: "${{ env.TAG }}"
run: |
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ With explore, for each repository, gitstronaut will give you information about:
- Pull requests: warning you about Pull Requests that are open and not merged
- Tags: warning you when the default branch is not aligned with the latest tag (and how many commits are between the two)

If you're using [changelogger](https://github.com/ctinnovation/changelogger) for handling your CHANGELOGs gitstronaut will also hint you the likely next release needed for that repo.
If you're using [changescribe](https://github.com/ctinnovation/changescribe) for handling your CHANGELOGs gitstronaut will also hint you the likely next release needed for that repo.

### Tags

Expand Down
2 changes: 1 addition & 1 deletion commands/print.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ async function printUnalignedRepo (ui, argv, repo, {
}, repo.default_branch)
} catch (e) {
ui.logger.info('unable to get any information about next release')
ui.logger.info(ui.colors.gray('💡 are you using https://github.com/ctinnovation/changelogger?'))
ui.logger.info(ui.colors.gray('💡 are you using https://github.com/ctinnovation/changescribe?'))
return
}

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
},
"scripts": {
"test": "exit 0",
"version": "git branch -D 'release_'$npm_package_version || true && git checkout -b 'release_'$npm_package_version && changelogger -p && git add .",
"version": "git branch -D 'release_'$npm_package_version || true && git checkout -b 'release_'$npm_package_version && changescribe && git add .",
"postversion": "git commit -mv$npm_package_version && git push --set-upstream origin 'release_'$npm_package_version"
},
"repository": {
Expand Down

0 comments on commit 9657b38

Please sign in to comment.