mirror of
https://github.com/privacy-protection-tools/anti-AD.git
synced 2025-02-13 17:12:41 +08:00
Create download-upstream.yml
This commit is contained in:
parent
f88cc2cff4
commit
0770a582ca
35
.github/workflows/download-upstream.yml
vendored
Normal file
35
.github/workflows/download-upstream.yml
vendored
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
# This is a basic workflow to help you get started with Actions
|
||||||
|
|
||||||
|
name: download upstream
|
||||||
|
|
||||||
|
# Controls when the action will run.
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||||
|
jobs:
|
||||||
|
# This workflow contains a single job called "build"
|
||||||
|
build:
|
||||||
|
# The type of runner that the job will run on
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
# Steps represent a sequence of tasks that will be executed as part of the job
|
||||||
|
steps:
|
||||||
|
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: prepare upstream list
|
||||||
|
run: |
|
||||||
|
git config --global user.email "action@github.com"
|
||||||
|
git config --global user.name "GitHub Action[bot]"
|
||||||
|
sudo update-alternatives --set php /usr/bin/php7.4
|
||||||
|
/bin/bash ./scripts/prepare-upstream.sh
|
||||||
|
git add *
|
||||||
|
git commit -am "download upstream."
|
||||||
|
- name: push
|
||||||
|
uses: ad-m/github-push-action@master
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.PERSON_TOKEN }}
|
||||||
|
- name: sync
|
||||||
|
run: |
|
||||||
|
curl -s -m 30 -X POST "$GITHUB_API_URL/repos/$GITHUB_REPOSITORY/actions/workflows/auto-rebuild.yml/dispatches" -H "Accept: application/vnd.github.v3+json" -H "Authorization: token ${{ secrets.PERSON_TOKEN }}" -d '{"ref":"adlist-maker"}'
|
Loading…
Reference in New Issue
Block a user