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

Stop attempting to comment link to RTD for non-PRs #2209

Merged
Merged
Changes from 1 commit
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
22 changes: 2 additions & 20 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,14 @@ on:
- release/*
paths:
- docs/**
pull_request_target:
types: [issues, opened, reopened, synchronize]
pull_request:
types: [opened, reopened, synchronize]
paths:
- docs/**

jobs:

documentation:

permissions:
pull-requests: 'write'

runs-on: ubuntu-latest
name: Build and deploy documentation
Expand Down Expand Up @@ -55,18 +52,3 @@ jobs:
name: documentation_warnings.log
path: artifact/doc_warnings.log
if-no-files-found: ignore

- name: Comment ReadDocs
uses: actions/github-script@v6
with:
script: |
const message = `
Link to ReadTheDocs sample build for this PR can be found at:
https://global-workflow--${{ github.event.pull_request.number }}.org.readthedocs.build/en/${{ github.event.pull_request.number }}
`
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: message
})