Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trigger on release published, remove auth from other actions #558

Merged
merged 3 commits into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions .github/workflows/changesets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,7 @@ jobs:
with:
node-version: 18.x
cache: npm

- name: Authenticate with private NPM package
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc



- name: Install dependencies
run: npm ci

Expand Down
19 changes: 6 additions & 13 deletions .github/workflows/cl-create.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
name: Create a changelog update
name: Changelog

on:
push:
tags:
- '@**'
- '**'
release:
types: [published]

jobs:
changelog:
Expand All @@ -25,11 +23,6 @@ jobs:
- name: Install dependencies
run: npm ci

- name: Set tag variable
run: |
TAG_NAME=${GITHUB_REF#refs/tags/}
echo "TAG_NAME=$TAG_NAME" >> $GITHUB_ENV

- name: Set variables from cl-config.yml
run: |
destinationRepo=$(yq e '.destinationRepo' cl-config.yml)
Expand All @@ -39,7 +32,7 @@ jobs:
echo "DESTINATION_DIRECTORY=${destinationDirectory}" >> $GITHUB_ENV

- name: Create a changelog update
run: npx changelog generate ${{ env.TAG_NAME }}
run: npx changelog generate tag ${{ github.event.release.tag_name }}
env:
CLAUDE_API_KEY: ${{ secrets.CLAUDE_API_KEY }}

Expand All @@ -56,7 +49,7 @@ jobs:
source_file: temp/${{ env.FILE_NAME}}
destination_repo: ${{ env.DESTINATION_REPO }}
destination_folder: changelog/src/${{ env.DESTINATION_DIRECTORY }}
destination_branch_create: changelog/${{ env.TAG_NAME }}
destination_branch_create: changelog/${{ github.event.release.tag_name }}
user_email: ${{ github.actor }}
user_name: github-actions[bot]
commit_message: "Updating the changelog for ${{ env.TAG_NAME }}"
commit_message: "Updating the changelog for ${{ github.event.release.tag_name }}"
3 changes: 0 additions & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,6 @@ jobs:
node-version: 16.x
cache: 'npm'

- name: Authenticate with private NPM package
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc

- name: Install Dependencies
run: npm ci

Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,7 @@ jobs:
with:
node-version: 16
cache: 'npm'

- name: Authenticate with private NPM package
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc


- name: Install dependencies
run: npm ci

Expand Down
14 changes: 7 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
"optionalDependencies": {
"@parcel/watcher-linux-x64-glibc": "^2.3.0",
"@rollup/rollup-linux-x64-gnu": "^4.8.0",
"@flatfile/changelog": "^0.0.3"
"@flatfile/changelog": "^1.0.0"

}
}
Loading