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

Bypass Push Rules for GitHub Action #391

Merged
merged 1 commit into from
Aug 14, 2023
Merged
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
10 changes: 9 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,22 @@ name: Format Docs and Code
on: [push, pull_request]

jobs:
prettier:
format:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
# Make sure the actual branch is checked out when running on pull requests
ref: ${{ github.head_ref }}
ssh-key: ${{ secrets.ACTION_PUSH }}

- name: Use lint-md to format Markdown
# For issues of Chinese characters in prettier:
# https://github.com/prettier/prettier/blob/e22a5516f5b2c44e6d68be4c0a7ba0b32c1b9f86/website/blog/2023-07-05-3.0.0.md?plain=1#L27
run: |
npm install --save-dev --save-exact @lint-md/cli
lint-md ./**/* --fix

- name: Prettify code
uses: creyD/prettier_action@v4.3
Expand Down
Loading