parent
f5f8c687be
commit
43d3fb3eba
@ -0,0 +1,24 @@ |
||||
# .github/release.yml |
||||
|
||||
changelog: |
||||
exclude: |
||||
labels: |
||||
- ignore-for-release |
||||
categories: |
||||
- title: Breaking Changes 🛠 |
||||
labels: |
||||
- Semver-Major |
||||
- breaking-change |
||||
- title: "Bug fixes :bug:" |
||||
labels: |
||||
- bug |
||||
- title: Exciting New Features 🎉 |
||||
labels: |
||||
- Semver-Minor |
||||
- enhancement |
||||
- title: 👒 Dependencies |
||||
labels: |
||||
- dependencies |
||||
- title: Other Changes |
||||
labels: |
||||
- "*" |
@ -0,0 +1,81 @@ |
||||
name: Build and Release |
||||
|
||||
on: push |
||||
|
||||
jobs: |
||||
build-linux: |
||||
strategy: |
||||
matrix: |
||||
include: |
||||
- build: 'avx2' |
||||
defines: '' |
||||
- build: 'avx' |
||||
defines: '-DLLAMA_AVX2=OFF' |
||||
- build: 'avx512' |
||||
defines: '-DLLAMA_AVX512=ON' |
||||
runs-on: ubuntu-latest |
||||
steps: |
||||
- name: Clone |
||||
uses: actions/checkout@v3 |
||||
with: |
||||
submodules: true |
||||
- name: Dependencies |
||||
run: | |
||||
sudo apt-get update |
||||
sudo apt-get install build-essential ffmpeg |
||||
- name: Build |
||||
id: build |
||||
env: |
||||
CMAKE_ARGS: "${{ matrix.define }}" |
||||
BUILD_ID: "${{ matrix.build }}" |
||||
run: | |
||||
make dist |
||||
- uses: actions/upload-artifact@v3 |
||||
with: |
||||
name: ${{ matrix.build }} |
||||
path: release/ |
||||
- name: Release |
||||
uses: softprops/action-gh-release@v1 |
||||
if: startsWith(github.ref, 'refs/tags/') |
||||
with: |
||||
files: | |
||||
release/* |
||||
|
||||
build-macOS: |
||||
strategy: |
||||
matrix: |
||||
include: |
||||
- build: 'avx2' |
||||
defines: '' |
||||
- build: 'avx' |
||||
defines: '-DLLAMA_AVX2=OFF' |
||||
- build: 'avx512' |
||||
defines: '-DLLAMA_AVX512=ON' |
||||
runs-on: macOS-latest |
||||
steps: |
||||
- name: Clone |
||||
uses: actions/checkout@v3 |
||||
with: |
||||
submodules: true |
||||
|
||||
- name: Dependencies |
||||
run: | |
||||
brew update |
||||
brew install sdl2 ffmpeg |
||||
- name: Build |
||||
id: build |
||||
env: |
||||
CMAKE_ARGS: "${{ matrix.define }}" |
||||
BUILD_ID: "${{ matrix.build }}" |
||||
run: | |
||||
make dist |
||||
- uses: actions/upload-artifact@v3 |
||||
with: |
||||
name: ${{ matrix.build }} |
||||
path: release/ |
||||
- name: Release |
||||
uses: softprops/action-gh-release@v1 |
||||
if: startsWith(github.ref, 'refs/tags/') |
||||
with: |
||||
files: | |
||||
release/* |
@ -1,26 +0,0 @@ |
||||
name: goreleaser |
||||
|
||||
on: |
||||
push: |
||||
tags: |
||||
- 'v*' |
||||
|
||||
jobs: |
||||
goreleaser: |
||||
runs-on: ubuntu-latest |
||||
steps: |
||||
- name: Checkout |
||||
uses: actions/checkout@v3 |
||||
with: |
||||
fetch-depth: 0 |
||||
- name: Set up Go |
||||
uses: actions/setup-go@v3 |
||||
with: |
||||
go-version: 1.18 |
||||
- name: Run GoReleaser |
||||
uses: goreleaser/goreleaser-action@v4 |
||||
with: |
||||
version: latest |
||||
args: release --clean |
||||
env: |
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
@ -1,15 +0,0 @@ |
||||
# Make sure to check the documentation at http://goreleaser.com |
||||
project_name: local-ai |
||||
builds: |
||||
- ldflags: |
||||
- -w -s |
||||
env: |
||||
- CGO_ENABLED=0 |
||||
goos: |
||||
- linux |
||||
- darwin |
||||
- windows |
||||
goarch: |
||||
- amd64 |
||||
- arm64 |
||||
binary: '{{ .ProjectName }}' |
Loading…
Reference in new issue