From 5969ce7d0643511ffcb6a3504d3c9563db5fccfc Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Fri, 8 Sep 2023 14:45:17 +0800 Subject: [PATCH] Test auto-create tag on push to prod --- .github/workflows/prodtag.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/workflows/prodtag.yml diff --git a/.github/workflows/prodtag.yml b/.github/workflows/prodtag.yml new file mode 100644 index 00000000..bf8bb824 --- /dev/null +++ b/.github/workflows/prodtag.yml @@ -0,0 +1,16 @@ +name: Auto-create tag on every push to `production` + +on: + push: + branches: + - production + +jobs: + tag: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + ref: production + - run: git tag -a "'{date +%d/%m/%Y} ({git rev-parse --short HEAD})'" $(git rev-parse HEAD) + - run: git push