convert subscription #5181
This file contains hidden or 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: convert subscription | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| - cron: '5 */1 * * *' | |
| watch: | |
| types: started | |
| jobs: | |
| convert: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 迁出代码 | |
| uses: actions/checkout@v4 | |
| - name: 安装Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.10' | |
| - name: 安装依赖 | |
| run: | | |
| pip install -r ./requirements.txt | |
| - name: 执行任务 | |
| run: | | |
| python ./convert.py | |
| - name: Commit | |
| run: | | |
| git config --global user.name "GitHub Actions" | |
| git config --global user.email "actions@github.com" | |
| git add . | |
| git commit -m "🚀️ Clash 订阅生成 $(date '+%Y-%m-%d %H:%M:%S')" | |
| - name: 推送更改 | |
| uses: ad-m/github-push-action@master | |
| with: | |
| # github_token: ${{ secrets.TOKEN }} | |
| branch: master |