Fix "Main playlists not updating" issue
This commit is contained in:
parent
1a5dbcbd82
commit
ed1950e8db
|
@ -5,20 +5,25 @@ on:
|
||||||
- cron: '0 1 * * *'
|
- cron: '0 1 * * *'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
generate:
|
deploy:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@master
|
uses: actions/checkout@master
|
||||||
|
|
||||||
- name: Generate Playlists and Deploy
|
- name: Install Dependencies
|
||||||
uses: JamesIves/github-pages-deploy-action@master
|
run: npm install
|
||||||
env:
|
|
||||||
|
- name: Generate Playlists
|
||||||
|
run: npm run generate
|
||||||
|
|
||||||
|
- name: Deploy to GitHub Pages
|
||||||
|
uses: JamesIves/github-pages-deploy-action@releases/v3
|
||||||
|
with:
|
||||||
ACCESS_TOKEN: ${{ secrets.REPO_SCOPED_TOKEN }}
|
ACCESS_TOKEN: ${{ secrets.REPO_SCOPED_TOKEN }}
|
||||||
BASE_BRANCH: master
|
BASE_BRANCH: master
|
||||||
BRANCH: gh-pages
|
BRANCH: gh-pages
|
||||||
FOLDER: .gh-pages
|
FOLDER: .gh-pages
|
||||||
BUILD_SCRIPT: npm install && npm run generate
|
|
||||||
update-readme:
|
update-readme:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: generate
|
needs: generate
|
||||||
|
|
|
@ -14,8 +14,6 @@ function main() {
|
||||||
parseIndex()
|
parseIndex()
|
||||||
console.log('Creating root directory...')
|
console.log('Creating root directory...')
|
||||||
createRootDirectory()
|
createRootDirectory()
|
||||||
console.log('Creating .nojekyll...')
|
|
||||||
createNoJekyllFile()
|
|
||||||
console.log('Generating index.m3u...')
|
console.log('Generating index.m3u...')
|
||||||
generateIndex()
|
generateIndex()
|
||||||
console.log('Generating index.country.m3u...')
|
console.log('Generating index.country.m3u...')
|
||||||
|
@ -41,10 +39,6 @@ function createRootDirectory() {
|
||||||
helper.createDir(ROOT_DIR)
|
helper.createDir(ROOT_DIR)
|
||||||
}
|
}
|
||||||
|
|
||||||
function createNoJekyllFile() {
|
|
||||||
helper.createFile(`${ROOT_DIR}/.nojekyll`)
|
|
||||||
}
|
|
||||||
|
|
||||||
function parseIndex() {
|
function parseIndex() {
|
||||||
const root = helper.parsePlaylist('index.m3u')
|
const root = helper.parsePlaylist('index.m3u')
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue