From 1c99fa334889732646a252e78581e551ef87de12 Mon Sep 17 00:00:00 2001 From: Samuel Chai Date: Mon, 21 Apr 2025 08:31:51 -0400 Subject: [PATCH 1/3] Moving the CLI tool from the version command --- .github/workflows/pr.yaml | 2 +- cmd/args.go | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index ec2843b..05f2cce 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -53,7 +53,7 @@ jobs: - name: Commit Files id: commit - uses: kassett/autocommit-changes@v1 + uses: kassett/autocommit-changes@2025-04-21-migrating-to-gh-commit with: commit-message: "Updating tracked Git version in source code" branch: ${{ github.head_ref }} diff --git a/cmd/args.go b/cmd/args.go index 9954435..7ccb64f 100644 --- a/cmd/args.go +++ b/cmd/args.go @@ -287,10 +287,9 @@ var rootCmd = &cobra.Command{ versionFlag, _ := cmd.Flags().GetBool("version") if versionFlag { - fmt.Printf("%s %s %s\n", + fmt.Printf("%s %s\n", color.New(color.FgBlue, color.Bold).Sprint("🔖 gh-commit"), color.New(color.FgGreen).Sprint(VERSION), - color.New(color.Faint).Sprint("(CLI tool)"), ) os.Exit(0) } From 9d37516e4e69b9e93178d5748bf3b70505699a62 Mon Sep 17 00:00:00 2001 From: Samuel Chai Date: Mon, 21 Apr 2025 08:38:42 -0400 Subject: [PATCH 2/3] Adding commit-all option --- .github/workflows/pr.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 05f2cce..32f03fe 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -57,4 +57,5 @@ jobs: with: commit-message: "Updating tracked Git version in source code" branch: ${{ github.head_ref }} - github-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + github-token: ${{ secrets.GITHUB_TOKEN }} + commit-all: 'true' \ No newline at end of file From f2448548d15765a1039c81bca17dd81fa86e28f0 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 21 Apr 2025 12:39:29 +0000 Subject: [PATCH 3/3] Updating tracked Git version in source code --- cmd/execute.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/execute.go b/cmd/execute.go index 305a89e..3e8238a 100644 --- a/cmd/execute.go +++ b/cmd/execute.go @@ -11,7 +11,7 @@ import ( ) // VERSION number: changed in CI -const VERSION = "v0.1.1" +const VERSION = "v0.1.2" var rootPath string var repo repository.Repository