Test actions-workflow #27
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: Update submodule in mikiken/mikiken.net | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
update_submodules: | |
name: Update submodules | |
runs-on: ubuntu-20.04 | |
defaults: | |
run: | |
working-directory: /home/runner/work/compiler_log/mikiken.net | |
steps: | |
- name: Clone repository | |
run: | | |
git clone https://github.com/mikiken/mikiken.net.git | |
cd mikiken.net | |
git init | |
pwd | |
ls -la | |
working-directory: /home/runner/work/compiler_log/ | |
- name: Configure git | |
run: | | |
pwd | |
git config --local user.name "mikiken" | |
git config --local user.email "[email protected]" | |
- name: Change revision of submodule | |
run: | | |
pwd | |
cd compiler_log | |
pwd | |
git fetch | |
git reset --hard origin/main | |
git status | |
- name: Add and commit files | |
run: | | |
pwd | |
git status | |
git add . | |
git commit -m "Update submodule via github-actions" | |
- name: Push changes | |
run : git push origin main |