mirror of
https://code.forgejo.org/actions/cascading-pr
synced 2025-03-15 14:54:40 +01:00
wait on the CI to complete
This commit is contained in:
parent
63ccad04bc
commit
df08855107
2 changed files with 3 additions and 3 deletions
|
@ -20,4 +20,4 @@ jobs:
|
||||||
- name: tests
|
- name: tests
|
||||||
run: |
|
run: |
|
||||||
FORGEJO_RUNNER_CONFIG=$(pwd)/tests/runner-config.yaml forgejo-runner.sh reload
|
FORGEJO_RUNNER_CONFIG=$(pwd)/tests/runner-config.yaml forgejo-runner.sh reload
|
||||||
tests/run.sh --debug --host_port ${{ steps.forgejo.outputs.host-port }} --url ${{ steps.forgejo.outputs.url }} --token ${{ steps.forgejo.outputs.token }}
|
tests/run.sh --host_port ${{ steps.forgejo.outputs.host-port }} --url ${{ steps.forgejo.outputs.url }} --token ${{ steps.forgejo.outputs.token }}
|
||||||
|
|
|
@ -62,6 +62,7 @@ function create_pull_request() {
|
||||||
git add .
|
git add .
|
||||||
git commit -m 'update'
|
git commit -m 'update'
|
||||||
git push origin branch1
|
git push origin branch1
|
||||||
|
git rev-parse HEAD > ../originrepo.sha
|
||||||
)
|
)
|
||||||
|
|
||||||
forgejo-curl.sh api_json --data-raw '{"title":"PR","base":"main","head":"branch1"}' ${options[url]}/api/v1/repos/user1/originrepo/pulls
|
forgejo-curl.sh api_json --data-raw '{"title":"PR","base":"main","head":"branch1"}' ${options[url]}/api/v1/repos/user1/originrepo/pulls
|
||||||
|
@ -91,8 +92,7 @@ function run() {
|
||||||
|
|
||||||
create_pull_request
|
create_pull_request
|
||||||
|
|
||||||
|
wait_success ${options[url]}/api/v1/repos/user1/originrepo $(cat $TMPDIR/originrepo.sha)
|
||||||
echo do something
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function main() {
|
function main() {
|
||||||
|
|
Loading…
Add table
Reference in a new issue