Update custom_script.yml #20
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run Custom Script | |
on: | |
push: | |
branches: | |
- master | |
env: | |
PROJECT_ID: ${{ vars.APIFOXPROJECTID }} | |
jobs: | |
run_script: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Run custom script | |
run: | | |
#cd path/to/script/directory | |
#echo "Hello World!" | |
# 执行脚本文件 | |
echo ${{ vars.APIFOXPROJECTID}} #仓库的变量 | |
echo ${{ secrets.APITOKEN }} #仓库密钥 | |
echo ${{ vars.TESTSKEY }} # 测试不存在的vars会发生什么 | |
echo ${{ env.PROJECT_ID }} | |
echo "end" | |
sudo sh ./hello.sh |