From 8430c40ada811fd0bd890daa21a802499ba1625d Mon Sep 17 00:00:00 2001 From: cpanato Date: Fri, 26 Apr 2024 17:48:46 +0200 Subject: [PATCH] debug --- .github/workflows/check-goreleaser.yaml | 17 +++++----- .goreleaser.yaml | 41 ++++++++++++++++++------- 2 files changed, 40 insertions(+), 18 deletions(-) diff --git a/.github/workflows/check-goreleaser.yaml b/.github/workflows/check-goreleaser.yaml index d1f567ee6..ce7727b53 100644 --- a/.github/workflows/check-goreleaser.yaml +++ b/.github/workflows/check-goreleaser.yaml @@ -12,6 +12,9 @@ jobs: check-goreleaser: runs-on: ubuntu-latest + container: + image: ghcr.io/gythialy/golang-cross:v1.22.2-0@sha256:642fda874607057c34dfbb2d7fce93dfa37bdb9dbc0cc74835d9c3157a7a0e89 + steps: - uses: actions/checkout@1d96c772d19495a3b5c517cd2bc0cb401ea0529f # v4.1.3 @@ -20,14 +23,14 @@ jobs: go-version: '1.22' check-latest: true - - name: install libyara-dev - run: | - sudo add-apt-repository -n -y "deb http://archive.ubuntu.com/ubuntu/ mantic main restricted universe multiverse" - sudo add-apt-repository -n -y "deb http://archive.ubuntu.com/ubuntu/ mantic-updates main restricted universe multiverse" - sudo add-apt-repository -n -y "deb http://archive.ubuntu.com/ubuntu/ mantic-backports main restricted universe multiverse" - sudo add-apt-repository -n -y "deb http://security.ubuntu.com/ubuntu mantic-security main restricted universe multiverse" + # - name: install libyara-dev + # run: | + # sudo add-apt-repository -n -y "deb http://archive.ubuntu.com/ubuntu/ mantic main restricted universe multiverse" + # sudo add-apt-repository -n -y "deb http://archive.ubuntu.com/ubuntu/ mantic-updates main restricted universe multiverse" + # sudo add-apt-repository -n -y "deb http://archive.ubuntu.com/ubuntu/ mantic-backports main restricted universe multiverse" + # sudo add-apt-repository -n -y "deb http://security.ubuntu.com/ubuntu mantic-security main restricted universe multiverse" - sudo apt update && sudo apt install libyara-dev -y + # sudo apt update && sudo apt install libyara-dev -y - name: Run GoReleaser uses: goreleaser/goreleaser-action@7ec5c2b0c6cdda6e8bbb49444bc797dd33d74dd8 # v5.0.0 diff --git a/.goreleaser.yaml b/.goreleaser.yaml index fc2ac32e1..8ea193737 100644 --- a/.goreleaser.yaml +++ b/.goreleaser.yaml @@ -3,24 +3,43 @@ project_name: bincapz before: hooks: - go mod tidy + - /bin/bash -c 'if [ -n "$(git --no-pager diff --exit-code go.mod go.sum)" ]; then exit 1; fi' builds: - - id: bincapz - binary: bincapz + # - id: bincapz + # binary: bincapz + # main: ./ + # goos: + # - darwin + # # - linux + # # - windows + # goarch: + # # - amd64 + # - arm64 + # # - arm + # flags: + # - -trimpath + # mod_timestamp: '{{ .CommitTimestamp }}' + # ldflags: + # - -X main.BuildVersion={{.Version}} + # env: + # - CGO_ENABLED=1 + + - id: darwin-amd64 + binary: bincapz-darwin-amd64 + no_unique_dist_dir: true + env: + - CC=o64-clang + - CXX=o64-clang++ + - CGO_ENABLED=1 main: ./ + flags: + - -trimpath + mod_timestamp: '{{ .CommitTimestamp }}' goos: - darwin - - linux - - windows goarch: - amd64 - - arm64 - - arm - flags: - - -trimpath - mod_timestamp: '{{ .CommitTimestamp }}' - ldflags: - - -X main.BuildVersion={{.Version}} signs: - id: bincapz