From 5bc82d548c9ba141a80b2df39d2154108f6f7816 Mon Sep 17 00:00:00 2001 From: cuisongliu Date: Sat, 18 Nov 2023 12:09:43 +0800 Subject: [PATCH] docs(main): auto release node using just Signed-off-by: cuisongliu --- .github/workflows/tagpr.yaml | 17 +++++++++++++++++ .tagpr | 5 +++++ justfile | 3 ++- 3 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/tagpr.yaml create mode 100644 .tagpr diff --git a/.github/workflows/tagpr.yaml b/.github/workflows/tagpr.yaml new file mode 100644 index 000000000..877c57bcc --- /dev/null +++ b/.github/workflows/tagpr.yaml @@ -0,0 +1,17 @@ +name: 🚀 tagpr +on: + push: + branches: + - test-release +jobs: + tagpr: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + token: ${{ secrets.GITHUB_TOKEN }} + - name: Install just + uses: taiki-e/install-action@just + - uses: Songmu/tagpr@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.tagpr b/.tagpr new file mode 100644 index 000000000..28c909bb0 --- /dev/null +++ b/.tagpr @@ -0,0 +1,5 @@ +[tagpr] + vPrefix = true + releaseBranch = test-release + versionFile = justfile + command = just version-up \ No newline at end of file diff --git a/justfile b/justfile index 321d580a6..b8dd35c5a 100644 --- a/justfile +++ b/justfile @@ -2,6 +2,7 @@ alias build := youki-release alias youki := youki-dev KIND_CLUSTER_NAME := 'youki' +version := 0.2.3 cwd := justfile_directory() @@ -189,7 +190,7 @@ ci-musl-prepare: ci-prepare echo "Unknown system. The CI is only configured for Ubuntu. You will need to forge your own path. Good luck!" exit 1 -version-up version: +version-up: git grep -l "^version = .* # MARK: Version" | xargs sed -i 's/version = "[0-9]\.[0-9]\.[0-9]" # MARK: Version/version = "{{version}}" # MARK: Version/g' git grep -l "} # MARK: Version" | grep -v justfile | xargs sed -i 's/version = "[0-9]\.[0-9]\.[0-9]" } # MARK: Version/version = "{{version}}" } # MARK: Version/g' {{ cwd }}/scripts/release_tag.sh {{version}} \ No newline at end of file