Skip to content

Commit

Permalink
update script
Browse files Browse the repository at this point in the history
  • Loading branch information
whitfiea committed Apr 24, 2024
1 parent 8d1367b commit 89a6713
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/update-internal-repo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,11 @@ jobs:
if: ${{ success() }}
run: $GITHUB_WORKSPACE/source/build/bin/copy-gitops.sh -s $GITHUB_WORKSPACE/source -t $GITHUB_WORKSPACE/target

- name: Setup git config
- name: Commit changes to remote repo
if: ${{ success() }}
run: |
cd $GITHUB_WORKSPACE/target
git config user.name "GitHub Actions Bot"
git config user.email "<>"
- name: Commit changes to remote repo
if: ${{ success() }}
run: |
echo "Push changes to ${{ env.GITHUB_BRANCH }} branch of https://github.ibm.com/${{ env.REMOTE_REPO }}"
git push origin ${{ env.GITHUB_BRANCH }}
3 changes: 3 additions & 0 deletions build/bin/copy-gitops.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ done
: ${SOURCE?"Need to set -s|--source argument for source directory"}
: ${TARGET?"Need to set -t|--target argument for target directory"}

echo "Deleting all files in target"
rm -rf ${TARGET}/*

echo "Copying gitops"
cp -vr ${SOURCE}/applications/* ${TARGET}/applications/
cp -vr ${SOURCE}/root-applications/* ${TARGET}/root-applications/
Expand Down

0 comments on commit 89a6713

Please sign in to comment.