37 lines
714 B
YAML
37 lines
714 B
YAML
name: Build and Release Proxy.pac
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- "master"
|
|
paths:
|
|
- '**/*.example'
|
|
- '**/*.js'
|
|
- '**/*.sh'
|
|
|
|
permissions: write-all
|
|
|
|
jobs:
|
|
build-and-release:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Set up Node.js
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: '16'
|
|
|
|
- name: Run build script
|
|
run: |
|
|
chmod +x ./build.sh
|
|
./build.sh
|
|
|
|
- name: Create release
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
sha: ${{ github.sha }}
|
|
run: |
|
|
gh release create "$(date '+%Y-%m-%d-')${sha:0:7}" --generate-notes ./proxy.pac |