mirror of
https://github.com/davegallant/rfd-redirect-stripper.git
synced 2025-08-06 08:43:40 +00:00
Generate tamper-monkey-script (#20)
* Generate tamper-monkey-script * Update script.js using gomplate --------- Co-authored-by: GitHub Actions <actions@users.noreply.github.com>
This commit is contained in:
30
.github/workflows/tamper-monkey.yaml
vendored
Normal file
30
.github/workflows/tamper-monkey.yaml
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
name: "Generate Tampermonkey script"
|
||||
on:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
gomplate:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
ref: ${{ github.event.pull_request.head.ref }}
|
||||
|
||||
- name: Install gomplate
|
||||
run: |
|
||||
wget -O gomplate https://github.com/hairyhenderson/gomplate/releases/download/v3.10.0/gomplate_linux-amd64
|
||||
chmod +x gomplate
|
||||
sudo mv gomplate /usr/local/bin/
|
||||
|
||||
- name: Run gomplate
|
||||
run: gomplate < script.js.tmpl > script.js
|
||||
|
||||
- name: Commit and push changes
|
||||
run: |
|
||||
git config --global user.name "GitHub Actions"
|
||||
git config --global user.email "actions@users.noreply.github.com"
|
||||
git add .
|
||||
git commit -m "Update script.js using gomplate" || true
|
||||
git push
|
Reference in New Issue
Block a user