Skip to content

releases

releases #5

Workflow file for this run

---
name: releases
on:
workflow_dispatch:
push:
tags:
- "v*"
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
# build targets
include:
- goos: linux
goarch: amd64
- goos: linux
goarch: '386'
- goos: darwin
goarch: amd64
- goos: darwin
goarch: arm64
steps:
- name: Checkout source code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.23
- name: Build for Linux-amd64
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
run: |
v=$(echo ${GITHUB_REF} | awk -F/ '{print substr($3,2,10);}')
go build -x -v -mod=vendor -ldflags "-X main.version=${v} -w -s" -o "tty-share_${GOOS}-${GOARCH}"
- name: Get tty-share
if: always()
run: |
curl -L https://github.com/elisescu/tty-share/releases/download/v2.4.0/tty-share_linux-amd64 -o tty-share
chmod u+x ./tty-share
export TERM=xterm-256color
./tty-share -A --public --headless --headless-cols 255 --headless-rows 50 --no-wait --listen :8001