app/.github/workflows/add_commit_info.yml
2024-06-01 15:05:45 +08:00

23 lines
569 B
YAML

name: Record Commit Hash
on: [push]
jobs:
record-hash:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Record commit hash
run: |
echo $(git rev-parse HEAD) > liteyuki/resources/vanilla_resource/commit.txt
- name: Commit and push
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add liteyuki/resources/vanilla_resource/commit.txt
git commit -m ":rocket: Record commit hash"
git push