Skip to content
Merged
Changes from all commits
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
36 changes: 0 additions & 36 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -206,39 +206,3 @@ jobs:
DOCSTRING: false
standalone_suffix: ${{ matrix.version == '241' && '.sp01' || '' }}
secrets: inherit

sync-main-with-master:
name: "Sync main with master"
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
runs-on: ubuntu-latest
steps:
- name: "Install Git and clone project"
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
token: ${{ secrets.MIGRATION_PAT }}
fetch-depth: 0

- name: "Verify that main is the default branch"
shell: bash
run: |
head_branch=$(git remote show origin | grep "HEAD branch:")
main_branch=${head_branch#*: }

if [[ $main_branch != "main" ]]; then
echo "The default branch is not 'main'. It is set to '$main_branch'."
echo "Please set 'main' as the default branch in the repository settings."
exit 1
fi

- name: "Configure git username and email"
shell: bash
run: |
git config --global user.name "${{ secrets.PYANSYS_CI_BOT_USERNAME }}"
git config --global user.email "${{ secrets.PYANSYS_CI_BOT_EMAIL }}"

- name: "Sync main to master"
shell: bash
run: |
git checkout master
git reset --hard main
git push
Loading