Merge pull request #47 from sjtushi/main #36
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: "CD-pages" | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
Website_Deployment: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Cancel Previous Runs | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ secrets.GITHUB_TOKEN }} | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Run linters | |
run: npx awesome-lint | |
- name: Copy latest README | |
run: | | |
cp README.md index.md | |
- name: Push latest index.md | |
uses: dmnemec/copy_file_to_another_repo_action@main | |
env: | |
API_TOKEN_GITHUB: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
source_file: "index.md" | |
destination_repo: "brootware/cyber-security-university" | |
destination_branch: "gh-pages" | |
user_email: "[email protected]" | |
user_name: "AwesomeCyberBot" | |
commit_message: "🤖 Updating website with latest content 📜" |