mirror of
https://github.com/Picocrypt/CLI.git
synced 2026-03-11 14:44:23 +00:00
Will be migrating hkdf and sha3 from golang.org/x/crypto into the standard library which is new to Go 1.24.
59 lines
1.6 KiB
YAML
59 lines
1.6 KiB
YAML
name: build
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
on:
|
|
push:
|
|
paths:
|
|
- "VERSION"
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-24.04
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Setup Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: '>=1.24'
|
|
check-latest: true
|
|
cache: false
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
cd picocrypt
|
|
go mod download
|
|
|
|
- name: Build
|
|
run: |
|
|
cd picocrypt
|
|
GOOS=windows GOARCH=amd64 go build -v -ldflags="-s -w" -o picocrypt-windows-amd64.exe .
|
|
GOOS=windows GOARCH=arm64 go build -v -ldflags="-s -w" -o picocrypt-windows-arm64.exe .
|
|
GOOS=darwin GOARCH=amd64 go build -v -ldflags="-s -w" -o picocrypt-macos-amd64 .
|
|
GOOS=darwin GOARCH=arm64 go build -v -ldflags="-s -w" -o picocrypt-macos-arm64 .
|
|
GOOS=linux GOARCH=amd64 go build -v -ldflags="-s -w" -o picocrypt-linux-amd64 .
|
|
GOOS=linux GOARCH=arm64 go build -v -ldflags="-s -w" -o picocrypt-linux-arm64 .
|
|
env:
|
|
CGO_ENABLED: 0
|
|
|
|
- name: Get version tag
|
|
run: |
|
|
VERSION=$(cat VERSION)
|
|
echo "VERSION=$VERSION" >> $GITHUB_ENV
|
|
|
|
- name: Release
|
|
uses: softprops/action-gh-release@v2
|
|
with:
|
|
files: |
|
|
picocrypt/picocrypt-windows-amd64.exe
|
|
picocrypt/picocrypt-windows-arm64.exe
|
|
picocrypt/picocrypt-macos-amd64
|
|
picocrypt/picocrypt-macos-arm64
|
|
picocrypt/picocrypt-linux-amd64
|
|
picocrypt/picocrypt-linux-arm64
|
|
tag_name: ${{ env.VERSION }}
|
|
make_latest: true
|