diff --git a/.github/workflows/nightly-build.yml b/.github/workflows/nightly-build.yml index ab1dcb1cf..d827e4847 100644 --- a/.github/workflows/nightly-build.yml +++ b/.github/workflows/nightly-build.yml @@ -10,7 +10,7 @@ name: Nightly Build on: push: branches: - - nightly0 # Just for test purpose only with the nightly repo + - nightly # Just for test purpose only with the nightly repo # This schedule will run only from the default branch schedule: - cron: '15 0 * * *' # run at 01:15 AM UTC @@ -53,14 +53,15 @@ jobs: # We can't push if no user name and email are configured git config user.name 'hustcer' git config user.email 'hustcer@outlook.com' - git fetch origin main - git remote add src https://github.com/nushell/nushell.git - git fetch src main - # git pull --rebase src main - # All the changes will be overwritten by the upstream main branch - git reset --hard src/main - git push origin main -f - let sha_short = (git rev-parse --short src/main | str trim | str substring 0..7) + git pull origin main + # --- COMMENT BEGIN: Comment the following lines to disable code syncing --- + # git remote add src https://github.com/nushell/nushell.git + # git fetch src main + # # All the changes will be overwritten by the upstream main branch + # git reset --hard src/main + # git push origin main -f + # --------------------------------- COMMENT END ---------------------------- + let sha_short = (git rev-parse --short origin/main | str trim | str substring 0..7) let tag_name = $'nightly-($sha_short)' if (git ls-remote --tags origin $tag_name | is-empty) { git tag -a $tag_name -m $'Nightly build from ($sha_short)'