Skip to content

Commit

Permalink
try random guess
Browse files Browse the repository at this point in the history
  • Loading branch information
mayank1513 committed Jan 1, 2025
1 parent 54068ab commit 7a50901
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
generate-docs:
if: github.event.repository.owner.login == 'react18-tools'
if: github.event.repository.owner.login == 'react18-tools' && !git diff ${{ github.event.before }}:lib/package.json lib/package.json
runs-on: ubuntu-latest
permissions:
contents: write
Expand All @@ -16,19 +16,6 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Check if package.json is modified
id: package_check
run: |
git pull
if git diff --name-only ${{ github.event.before }} ${{ github.sha }} | grep -q "lib/package.json"; then
echo "file_changed=true" >> $GITHUB_ENV
else
echo "file_changed=false" >> $GITHUB_ENV
fi
- name: Exit if lib/package has changed
if: env.file_changed == 'false'
run: exit 1

- uses: actions/setup-node@v4
with:
registry-url: https://registry.npmjs.org
Expand Down

0 comments on commit 7a50901

Please sign in to comment.