Skip to content

Add README for examples folder #234

Add README for examples folder

Add README for examples folder #234

Workflow file for this run

name: Test Release
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-linux:
name: Linux build
runs-on: ubuntu-latest
steps:
- name: Get tag
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
shell: bash
- uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: '1.22.x'
- name: Install dependencies
run: |
go get ./...
- name: Build
run: |
GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" ./cmd/bbn
GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" ./cmd/bbni
- name: Compress binaries
run: |
tar -czf bbn.tar.gz bbn bbni _examples
shell: bash
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: bbn-linux-amd64.tar.gz
path: bbn.tar.gz
build-windows:
name: Windows build
runs-on: ubuntu-latest
steps:
- name: Get tag
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
shell: bash
- uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: '1.22.x'
- name: Install dependencies
run: |
go get ./...
- name: Build
run: |
GOOS=windows GOARCH=amd64 go build -ldflags="-s -w" ./cmd/bbn
GOOS=windows GOARCH=amd64 go build -ldflags="-s -w" ./cmd/bbni
- name: Compress binaries
run: |
zip -r bbn.zip bbn.exe bbni.exe _examples
shell: bash
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: bbn-windows-amd64.zip
path: bbn.zip
build-macos-arm64:
name: MacOS arm64 build
runs-on: macos-latest
steps:
- name: Get tag
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
shell: bash
- uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: '1.22.x'
- name: Install dependencies
run: |
go get ./...
- name: Build
run: |
GOOS=darwin GOARCH=arm64 go build -ldflags="-s -w" ./cmd/bbn
GOOS=darwin GOARCH=arm64 go build -ldflags="-s -w" ./cmd/bbni
- name: Compress binaries
run: |
zip -r bbn.zip bbn bbni _examples
shell: bash
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: bbn-macos-arm64.zip
path: bbn.zip
build-macos-amd64:
name: MacOS amd64 build
runs-on: macos-latest
steps:
- name: Get tag
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
shell: bash
- uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: '1.22.x'
- name: Install dependencies
run: |
go get ./...
- name: Build
run: |
GOOS=darwin GOARCH=amd64 go build -ldflags="-s -w" ./cmd/bbn
GOOS=darwin GOARCH=amd64 go build -ldflags="-s -w" ./cmd/bbni
- name: Compress binaries
run: |
zip -r bbn.zip bbn bbni _examples
shell: bash
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: bbn-macos-amd64.zip
path: bbn.zip