Skip to content

Commit

Permalink
Merge pull request #32 from savitaashture/add-opc-release-v1.15.x
Browse files Browse the repository at this point in the history
Add opc release-v1.15.x branch
  • Loading branch information
savitaashture authored May 20, 2024
2 parents f8b1120 + fa6f7dd commit 8e8fdc7
Show file tree
Hide file tree
Showing 2,671 changed files with 304,842 additions and 182,487 deletions.
7 changes: 0 additions & 7 deletions opc/.errcheck.txt

This file was deleted.

4 changes: 2 additions & 2 deletions opc/.github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.20'
go-version: '1.22'

- uses: actions/cache@v4
with:
Expand Down Expand Up @@ -45,7 +45,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.20'
go-version: '1.22'

- uses: actions/cache@v4
with:
Expand Down
4 changes: 2 additions & 2 deletions opc/.github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ jobs:

- uses: actions/setup-go@v5
with:
go-version: '1.20'
go-version: '1.22'

- uses: goreleaser/goreleaser-action@v5.0.0
- uses: goreleaser/goreleaser-action@v5.1.0
with:
version: latest
args: release --timeout=60m --clean
Expand Down
7 changes: 3 additions & 4 deletions opc/.golangci.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
issues:
exclude-dirs:
- vendor
run:
build-tags:
- e2e
skip-dirs:
- vendor
linters-settings:
gocritic:
disabled-checks:
- unlambda
errcheck:
exclude: .errcheck.txt
gofumpt:
extra-rules: true
linters:
Expand Down
22 changes: 11 additions & 11 deletions opc/Formula/opc.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
class Opc < Formula
desc "A CLI for OpenShift Pipeline"
homepage "https://github.com/openshift-pipelines/opc"
version "1.14.0"
version "1.14.3"

on_macos do
if Hardware::CPU.arm?
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.0/opc_1.14.0_darwin_arm64.tar.gz"
sha256 "64352d29d33c802b484993e18684453d859f27d257ab4a74f319c3dd6446d5d3"
if Hardware::CPU.intel?
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.3/opc_1.14.3_darwin_x86_64.tar.gz"
sha256 "d6cb42f47a1f4f573cf27d93de120389381a12fece959e8bd539c25ea1502fff"

def install
bin.install "opc" => "opc"
Expand All @@ -21,9 +21,9 @@ def install
prefix.install_metafiles
end
end
if Hardware::CPU.intel?
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.0/opc_1.14.0_darwin_x86_64.tar.gz"
sha256 "3a6db4f978c4c2cc036c7f83a8b0e4e15a4afb4afb4f1c3bb073c5ac20b3a8a7"
if Hardware::CPU.arm?
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.3/opc_1.14.3_darwin_arm64.tar.gz"
sha256 "f4f980104dbcc4562c0dc98f02d543f659d3ffae0b3a77d67a815c7df3e9f89b"

def install
bin.install "opc" => "opc"
Expand All @@ -38,8 +38,8 @@ def install

on_linux do
if Hardware::CPU.arm? && Hardware::CPU.is_64_bit?
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.0/opc_1.14.0_linux_arm64.tar.gz"
sha256 "093998eb1dde9454ca485a02ae93e6189b557f5265c5ab5e82e095c73268f45c"
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.3/opc_1.14.3_linux_arm64.tar.gz"
sha256 "f1185e96cef3f380f1c59ddd4ff31998fdc92a9cbc17ed152f69bd32569f3475"

def install
bin.install "opc" => "opc"
Expand All @@ -51,8 +51,8 @@ def install
end
end
if Hardware::CPU.intel?
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.0/opc_1.14.0_linux_x86_64.tar.gz"
sha256 "8a30f275a1cab2082290b51d87648e6681d7356af5783641e5860522c2911327"
url "https://github.com/openshift-pipelines/opc/releases/download/v1.14.3/opc_1.14.3_linux_x86_64.tar.gz"
sha256 "f9b96cb1fd96e0be773d9918438609529f077b5ed09748028ed7a3478d217fa1"

def install
bin.install "opc" => "opc"
Expand Down
13 changes: 8 additions & 5 deletions opc/Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
PAC_VERSION := $(shell sed -n '/[ ]*github.com\/openshift-pipelines\/pipelines-as-code v[0-9]*\.[0-9]*\.[0-9]*/ { s/.* v//;p ;}' go.mod)
TKN_VERSION := $(shell sed -n '/[ ]*github.com\/tektoncd\/cli v[0-9]*\.[0-9]*\.[0-9]*/ { s/.* v//;p ;}' go.mod)
RESULTS_VERSION := $(shell sed -n '/[ ]*github.com\/tektoncd\/results v[0-9]*\.[0-9]*\.[0-9]*/ { s/.* v//;p ;}' go.mod)
MAG_VERSION := $(shell sed -n '/[ ]*github.com\/openshift-pipelines\/manual-approval-gate v[0-9]*\.[0-9]*\.[0-9]*/ { s/.* v//;p ;}' go.mod)

GO := go
GOVERSION := 1.20
GOVERSION := 1.22
OPC_VERSION := devel
BINARYNAME := opc
GOLANGCI_LINT := golangci-lint
Expand All @@ -26,13 +27,15 @@ build: mkbin generate ## builds binary and updates version in pkg/version
windows: mkbin generate
env GOOS=windows GOARCH=amd64 $(GO) build -mod=vendor $(FLAGS) -v -o bin/$(BINARYNAME).exe main.go

generate: version-file ## updates version of pipeline-as-code, cli and results in pkg/version file
generate: version-file ## updates version of pipeline-as-code, cli, mag and results in pkg/version file
version-file:
echo '{"pac": "$(PAC_VERSION)", "tkn": "$(TKN_VERSION)", "results": "$(RESULTS_VERSION)", "opc": "$(OPC_VERSION)"}' > pkg/version.json
echo '{"pac": "$(PAC_VERSION)", "tkn": "$(TKN_VERSION)", "results": "$(RESULTS_VERSION)", "manualapprovalgate": "$(MAG_VERSION)", "opc": "$(OPC_VERSION)"}' > pkg/version.json

version-updates: ## updates pipeline-as-code, cli and results version in go.mod
version-updates: ## updates pipeline-as-code, cli, mag and results version in go.mod
$(GO) get -u github.com/openshift-pipelines/pipelines-as-code
$(GO) mod vendor
$(GO) get -u github.com/openshift-pipelines/manual-approval-gate
$(GO) mod vendor
$(GO) get -u github.com/tektoncd/cli
$(GO) mod vendor
$(GO) get -u github.com/tektoncd/results
Expand All @@ -47,7 +50,7 @@ lint-go: ## runs go linter on all go files
@$(GOLANGCI_LINT) run ./... --modules-download-mode=vendor \
--max-issues-per-linter=0 \
--max-same-issues=0 \
--deadline 10m
--timeout 10m

.PHONY: generate version-file version-updates updates build all vendor tidy lint-go mkbin

Expand Down
Loading

0 comments on commit 8e8fdc7

Please sign in to comment.