ci: cleanup workflows (#327)

This commit is contained in:
uncenter authored and GitHub committed 2023-11-18 04:20:49 +01:00
1 parent c7a5c79910
commit 0814bb215d
9 files changed
+38 -33

No files matched your search

+5 -3
View File
@@ -6,16 +6,18 @@ on:
jobs: jobs:
format: format:
name: Format Code name: Format userstyles
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
with: with:
token: ${{ secrets.USERSTYLES_TOKEN }} token: ${{ secrets.USERSTYLES_TOKEN }}
- uses: actions/setup-node@v3
- name: Format files - name: Setup Node.js
uses: actions/setup-node@v3
- name: Format userstyles
run: npx prettier --write styles/**/*.css run: npx prettier --write styles/**/*.css
- name: Pull changes - name: Pull changes
+1 -2
View File
@@ -12,8 +12,8 @@ env:
jobs: jobs:
generate-health-files: generate-health-files:
runs-on: ubuntu-latest
name: Generate health files name: Generate health files
runs-on: ubuntu-latest
permissions: permissions:
# Give the default GITHUB_TOKEN write permission to commit and push the # Give the default GITHUB_TOKEN write permission to commit and push the
# added or changed files to the repository. # added or changed files to the repository.
@@ -52,4 +52,3 @@ jobs:
commit_message: "chore: generate health files" commit_message: "chore: generate health files"
commit_author: "github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>" commit_author: "github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>"
branch: ${{ github.ref }} branch: ${{ github.ref }}
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
+8 -8
View File
@@ -11,11 +11,11 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: github/issue-label[email protected] - name: Add issue labels
with: uses: github/[email protected]
repo-token: "${{ secrets.GITHUB_TOKEN }}" with:
configuration-path: .github/issue-labeler.yml repo-token: "${{ secrets.GITHUB_TOKEN }}"
enable-versioned-regex: 0 configuration-path: .github/issue-labeler.yml
include-title: 1 enable-versioned-regex: 0
sync-labels: 1 include-title: 1
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json sync-labels: 1
-1
View File
@@ -12,7 +12,6 @@ env:
jobs: jobs:
lint: lint:
name: Lint Userstyles name: Lint Userstyles
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
+1 -3
View File
@@ -11,8 +11,8 @@ env:
jobs: jobs:
sync-maintainers: sync-maintainers:
runs-on: ubuntu-latest
name: Sync maintainers name: Sync maintainers
runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
@@ -36,5 +36,3 @@ jobs:
run: deno task sync-maintainers run: deno task sync-maintainers
env: env:
GITHUB_TOKEN: ${{ secrets.USERSTYLES_TOKEN }} GITHUB_TOKEN: ${{ secrets.USERSTYLES_TOKEN }}
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
+1
View File
@@ -10,6 +10,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
permissions: permissions:
pull-requests: write pull-requests: write
steps: steps:
- name: Lint pull request title - name: Lint pull request title
uses: amannn/action-semantic-pull-request@v5 uses: amannn/action-semantic-pull-request@v5
+3 -1
View File
@@ -10,7 +10,9 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: actions/[email protected]
- name: Add pull request labels
uses: actions/[email protected]
with: with:
configuration-path: .github/pr-labeler.yml configuration-path: .github/pr-labeler.yml
sync-labels: true sync-labels: true
+4 -2
View File
@@ -9,10 +9,12 @@ on:
jobs: jobs:
update: update:
name: Update name: Sync labels
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: r7kamura/github-label-sync-action@v0 - name: Sync labels
uses: r7kamura/github-label-sync-action@v0
if: ${{ github.repository == 'catppuccin/userstyles' }} if: ${{ github.repository == 'catppuccin/userstyles' }}
with: with:
allow_added_labels: "true" allow_added_labels: "true"
+15 -13
View File
@@ -11,18 +11,20 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: crate-ci/typos@master
id: typos
continue-on-error: true
# 'continue-on-error' will always succeed, we should exit based on the outcome and not the conclusion - name: Check for typos
# ref: https://docs.github.com/en/actions/learn-github-actions/contexts#steps-context uses: crate-ci/typos@master
- name: Fail when typos are found in pull request id: typos
if: ${{ github.event_name == 'pull_request' && steps.typos.outcome != 'success' }} continue-on-error: true
run: "exit 1"
# We always want this check to pass on branch 'main' but continue to fail on PRs # 'continue-on-error' will always succeed, we should exit based on the outcome and not the conclusion
- name: Pass on 'main' branch # ref: https://docs.github.com/en/actions/learn-github-actions/contexts#steps-context
if: ${{ github.repository == 'catppuccin/userstyles' && github.ref == 'refs/heads/main' }} - name: Fail when typos are found in pull request
run: "exit 0" if: ${{ github.event_name == 'pull_request' && steps.typos.outcome != 'success' }}
run: "exit 1"
# We always want this check to pass on branch 'main' but continue to fail on PRs
- name: Pass on 'main' branch
if: ${{ github.repository == 'catppuccin/userstyles' && github.ref == 'refs/heads/main' }}
run: "exit 0"