File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Create Pull Request
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ branch :
7+ description : ' Branch name to create PR from'
8+ required : true
9+ default : ' cursor-test-1769836655'
10+ title :
11+ description : ' PR Title'
12+ required : true
13+ default : ' Test PR - Automated PR Creation Demo'
14+ base :
15+ description : ' Base branch'
16+ required : true
17+ default : ' main'
18+
19+ jobs :
20+ create-pr :
21+ runs-on : ubuntu-latest
22+ permissions :
23+ contents : read
24+ pull-requests : write
25+
26+ steps :
27+ - name : Checkout
28+ uses : actions/checkout@v4
29+ with :
30+ ref : ${{ github.event.inputs.branch }}
31+
32+ - name : Create Pull Request
33+ env :
34+ GH_TOKEN : ${{ github.token }}
35+ run : |
36+ gh pr create \
37+ --title "${{ github.event.inputs.title }}" \
38+ --body "This is a test pull request created automatically to demonstrate the PR creation workflow. This PR can be safely closed or merged." \
39+ --base "${{ github.event.inputs.base }}" \
40+ --head "${{ github.event.inputs.branch }}"
You can’t perform that action at this time.
0 commit comments