mirror of
https://github.com/zed-industries/zed.git
synced 2025-01-24 11:01:54 +00:00
efb6342e9d
Only run actions dependency-review-action if running in a PR action. This broke when run as part of action for commit on main and on a preview branch: - https://github.com/zed-industries/zed/actions/runs/12793068921/job/35664998296 - https://github.com/zed-industries/zed/actions/runs/12793045639 Originally introduced in: - https://github.com/zed-industries/zed/pull/21424 But was only tested with `merge_group` which has since been reverted.
37 lines
926 B
YAML
37 lines
926 B
YAML
name: Docs
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- "docs/**"
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
check_formatting:
|
|
name: "Check formatting"
|
|
if: github.repository_owner == 'zed-industries'
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
|
|
|
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
|
|
with:
|
|
version: 9
|
|
|
|
- name: Prettier Check on /docs
|
|
working-directory: ./docs
|
|
run: |
|
|
pnpm dlx prettier . --check || {
|
|
echo "To fix, run from the root of the zed repo:"
|
|
echo " cd docs && pnpm dlx prettier . --write && cd .."
|
|
false
|
|
}
|
|
|
|
- name: Check for Typos with Typos-CLI
|
|
uses: crate-ci/typos@8e6a4285bcbde632c5d79900a7779746e8b7ea3f # v1.24.6
|
|
with:
|
|
config: ./typos.toml
|
|
files: ./docs/
|