dl_youtube.yml 636 B

123456789101112131415161718192021
  1. name: "youutbe downlaoder"
  2. on: [push, pull_request]
  3. jobs:
  4. build:
  5. runs-on: ubuntu-latest
  6. steps:
  7. - name: Clone repository
  8. uses: actions/checkout@v4
  9. - name: download video
  10. run: |
  11. git config --local user.email "xx"
  12. git config --local user.name "xx"
  13. git remote set-url origin https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
  14. git pull --rebase
  15. ./bin/youtube-dl -o "downloads/%(id)s.%(ext)s" --batch-file='./playlist.txt'
  16. git add .
  17. git commit -m "download youtube video"
  18. git push