Merge pull request #225 from RTUITLab/sync/master #180
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: Build front | |
| on: | |
| push: | |
| branches: [ master ] | |
| pull_request: | |
| branches: [ master ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node-version: [16.x] | |
| # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ | |
| steps: | |
| - uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 0 | |
| ref: gh-pages | |
| - run: git checkout -b gh-pages-pr || true | |
| - run: git push --set-upstream origin gh-pages-pr || true | |
| - uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 0 | |
| ref: gh-pages-pr | |
| - run: git config --global user.email "bk@finebot.site" | |
| - run: git config --global user.name "baikinkirill" | |
| - run: git merge origin/gh-pages --allow-unrelated-histories -X gh-pages | |
| - run: git add . | |
| - run: git commit -m "Merge branch gh-pages into gh-pages-pr" 1> /dev/null 2> /dev/null || true | |
| - run: git push | |
| - uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 0 | |
| ref: master | |
| - name: Use Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v2 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: 'npm' | |
| - run: git submodule update --init --recursive -j 8 | |
| - run: npm ci | |
| - run: npx jake token=${{ secrets.RTUITLAB_LANDING_TOKEN }} | |
| - name: Deploy 🚀 | |
| uses: JamesIves/github-pages-deploy-action@4.1.5 | |
| with: | |
| branch: gh-pages-pr | |
| folder: build | |
| clean: true | |
| - run: echo ${{ secrets.GITHUB_TOKEN }} | gh auth login --with-token | |
| - run: gh pr create --title "New landing build" --base gh-pages --head gh-pages-pr --body "" -a baikinkirill,ivlaptev || true | |