-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e881811
commit 8bcfc30
Showing
1 changed file
with
3 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,73 +6,30 @@ on: | |
workflow_dispatch: | ||
|
||
env: | ||
SOURCE_DIR: ./src/ | ||
TARGET_OWNER: larshinueber | ||
TARGET_REPO: foo-space | ||
TARGET_DIR: docs/source/_src_getting_started/_src_examples/notebooks/foopy-examples | ||
USER_NAME: github-actions | ||
USER_EMAIL: [email protected] | ||
|
||
jobs: | ||
sync: | ||
# if: github.event.pull_request.merged == true | ||
runs-on: ubuntu-latest | ||
env: | ||
# BRANCH_NAME: man-repo-sync-${{ github.event_name == 'pull_request' && github.event.pull_request.number || 'dispatch' }} | ||
GH_TOKEN: ${{ secrets.GH_PAT }} | ||
steps: | ||
# - name: Checkout source repository | ||
# uses: actions/checkout@v4 | ||
- name: Checkout target repository | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: ${{ env.TARGET_OWNER }}/${{ env.TARGET_REPO }} | ||
# token: ${{ secrets.GH_PAT }} | ||
token: ${{ secrets.GH_PAT }} | ||
ref: submodules | ||
# submodules: true | ||
# path: ./${{ env.TARGET_REPO }} | ||
|
||
- name: Fetch new commits | ||
run: | | ||
# git pull --recurse-submodules | ||
# git submodule update --remote --recursive | ||
# git submodule update --remote | ||
# cd ${{ env.TARGET_DIR }} | ||
# git checkout -b submodules | ||
# git pull | ||
# git status | ||
# git submodule foreach git pull | ||
git submodule update --init --recursive | ||
git submodule update --recursive --remote | ||
# git submodule update --remote | ||
- name: Commit and push changes | ||
uses: stefanzweifel/git-auto-commit-action@v5 | ||
with: | ||
commit_message: "Update submodule to ${{ github.event.after }}" | ||
|
||
|
||
# - name: Create new branch | ||
# run: | | ||
# bash .github/scripts/checkout_branch.sh ${{ env.TARGET_REPO }} ${{ env.BRANCH_NAME }} ${{ env.USER_EMAIL }} ${{ env.USER_NAME }} | ||
|
||
# - name: Delete old files | ||
# run: | | ||
# rm -rf ${{ env.TARGET_DIR }} | ||
|
||
# - name: Setup Python | ||
# uses: actions/setup-python@v2 | ||
# with: | ||
# python-version: '3.11' | ||
|
||
# - name: Copy new files | ||
# run: | | ||
# python .github/scripts/copy_notebooks.py ${{ env.SOURCE_DIR }} ${{ env.TARGET_DIR }} | ||
|
||
# - name: Push changes | ||
# run: | | ||
# bash .github/scripts/commit_and_push.sh ${{ env.TARGET_REPO }} ${{ env.BRANCH_NAME }} | ||
|
||
# - name: Create PR | ||
# run: | | ||
# bash .github/scripts/create_pr.sh ${{ env.TARGET_REPO }} ${{ env.BRANCH_NAME }} |