From a16ef00e888fc8778fb0145e86aa465990220210 Mon Sep 17 00:00:00 2001 From: aler9 <46489434+aler9@users.noreply.github.com> Date: Thu, 30 May 2024 23:00:12 +0200 Subject: [PATCH] temp --- .github/workflows/code_test.yml | 11 ++++++++--- internal/core/versiongetter/main.go | 11 +++++++++++ 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/.github/workflows/code_test.yml b/.github/workflows/code_test.yml index bb5a1409..42aebda0 100644 --- a/.github/workflows/code_test.yml +++ b/.github/workflows/code_test.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - run: make test @@ -23,7 +23,7 @@ jobs: runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - run: make test32 @@ -31,10 +31,15 @@ jobs: runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: actions/setup-go@v2 with: go-version: "1.22" + - name: GitHub Tag Name example + run: | + echo "Tag name from GITHUB_REF_NAME: $GITHUB_REF_NAME" + echo "Tag name from github.ref_name: ${{ github.ref_name }}" + - run: make test-highlevel-nodocker diff --git a/internal/core/versiongetter/main.go b/internal/core/versiongetter/main.go index c406edbc..80965223 100644 --- a/internal/core/versiongetter/main.go +++ b/internal/core/versiongetter/main.go @@ -3,6 +3,7 @@ package main import ( "bytes" + "fmt" "html/template" "log" "os" @@ -19,7 +20,17 @@ const version = "{{ .Version }}" func do() error { log.Println("getting version...") + temp, _ := exec.Command("git", "status").CombinedOutput() + /*if err != nil { + return err + }*/ + + fmt.Println(string(temp)) + stdout, err := exec.Command("git", "describe", "--tags").Output() + + fmt.Println(string(stdout)) + if err != nil { return err }