Skip to content

test: resolve windows test failures #2

test: resolve windows test failures

test: resolve windows test failures #2

Workflow file for this run

name: cd
on:
push:
branches:
- main
jobs:
setup:
runs-on: ubuntu-latest
steps:
- name: checkout-code
uses: actions/checkout@v4
- name: set-up-go
uses: actions/setup-go@v5
- name: install-deps
run: make deps
build:
needs: setup
runs-on: ubuntu-latest
strategy:
matrix:
os: [linux, windows]
arch: [amd64, arm64]
steps:
- name: build
run: |
GOOS=${{ matrix.os }} GOARCH=${{ matrix.arch }} make build
prepare:
needs: build
runs-on: ubuntu-latest
steps:
- name: get-version
run: make get-version
- name: check-tag-exists
run: make check-tag-exists
- name: create-github-release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ env.VERSION }}
release_name: Release ${{ env.VERSION }}
draft: false
prerelease: false
release:
needs: build
runs-on: ubuntu-latest
strategy:
matrix:
os: [linux, windows]
arch: [amd64, arm64]
steps:
- name: upload-executable
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./lenv-${{ matrix.os }}-${{ matrix.arch }}
asset_name: lenv-${{ matrix.os }}-${{ matrix.arch }}${{ matrix.os == 'windows' && '.exe' || '' }}
asset_content_type: application/octet-stream