Skip to content

Commit

Permalink
Merge pull request #12 from ppyv/test-replace
Browse files Browse the repository at this point in the history
Automated replacing a string of auto-pr.ps1
  • Loading branch information
ppyv committed Mar 28, 2023
2 parents 54488b1 + ceb685e commit c135811
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 15 deletions.
16 changes: 1 addition & 15 deletions .github/workflows/template-sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,24 +25,10 @@ jobs:
with:
token: ${{ steps.generate_token.outputs.token }}
- name: actions-template-sync
id: actions_template_sync
uses: AndreasAugustin/actions-template-sync@v0.8.0
with:
github_token: ${{ steps.generate_token.outputs.token }}
source_repo_path: ScoopInstaller/BucketTemplate
upstream_branch: master
is_allow_hooks: true
# pr_labels: <label1>,<label2>[,...] # optional, no default
- name: "[debug] dump steps"
run: echo '${{ toJSON(steps) }}'
- name: Find and Replace
uses: jacobtomlinson/gha-find-replace@v3
with:
find: "<username>/<bucketname>"
replace: "ppyv/scoop-jp-fonts"
include: bin/auto-pr.ps1
regex: false
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ steps.generate_token.outputs.token }}
branch: ${{ github.head_ref }}
7 changes: 7 additions & 0 deletions templatesync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
hooks:
prepush:
commands:
- echo 'replacing placeholder'
- sed -i s/<username>\/<bucketname>/ppyv\/scoop-jp-fonts/g bin/auto-pr.ps1
- git add bin/auto-pr.ps1
- git commit -m placeholder

0 comments on commit c135811

Please sign in to comment.