From 46052aebc4152ccaed0701da5c876f6b8211c308 Mon Sep 17 00:00:00 2001 From: im-deviprakash Date: Tue, 23 Jan 2024 12:00:10 +0530 Subject: [PATCH] Added build for Go Package --- .github/workflows/build.yml | 29 +++++++++++++++++++++++++++++ go.mod | 5 +++-- 2 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..173e329 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,29 @@ +name: Go + +on: [push,pull_request] + +jobs: + build: + + runs-on: ubuntu-latest + strategy: + matrix: + go-version: [ '1.19', '1.20', '1.21.x' ] + + steps: + - uses: actions/checkout@v4 + - name: Setup Go ${{ matrix.go-version }} + uses: actions/setup-go@v4 + with: + go-version: ${{ matrix.go-version }} + + - name: Display Go version + run: go version + + - name: Install dependencies + run: | + go mod download github.com/ingrammicro-xvantage/xi-sdk-resellers-go + go get golang.org/x/oauth2 + go get . + - name: Build + run: go build -v ./... diff --git a/go.mod b/go.mod index 7020685..67c74cb 100644 --- a/go.mod +++ b/go.mod @@ -1,7 +1,8 @@ -module github.com/GIT_USER_ID/GIT_REPO_ID +module github.com/ingrammicro-xvantage/xi-sdk-resellers-go + -go 1.18 require ( golang.org/x/oauth2 v0.0.0-20210323180902-22b0adad7558 ) +go 1.18 \ No newline at end of file