Skip to content

Commit

Permalink
ci: Fix workflows (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
bicstone authored Feb 23, 2024
1 parent bc08484 commit 2b07b74
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 7 deletions.
20 changes: 14 additions & 6 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ on:
- main
workflow_dispatch:

permissions:
contents: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
Expand All @@ -21,8 +18,19 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.GH_PAT_CHECKOUT }}
fetch-depth: 0
- uses: increments/qiita-cli/actions/publish@v1
- uses: actions/setup-node@v4
with:
qiita-token: ${{ secrets.QIITA_TOKEN }}
root: "."
node-version-file: ".node-version"
cache: "npm"
- run: npm ci
- run: npm run qiita publish --all
env:
QIITA_TOKEN: ${{ secrets.QIITA_TOKEN }}
- run: |
git add ./public/*
if ! git diff --staged --exit-code --quiet; then
git commit -m 'Updated by qiita-cli'
git push --force
fi
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Test

on:
- push
- pull_request
- workflow_dispatch

jobs:
build:
Expand Down
1 change: 1 addition & 0 deletions .husky/pre-push
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
npm run lint

0 comments on commit 2b07b74

Please sign in to comment.