Skip to content

Commit

Permalink
chore: add linux static build (TabbyML#379)
Browse files Browse the repository at this point in the history
* chore: add linux static build

* add touch

* update build env

* add sudo

* fix: protobuf ubuntu target
  • Loading branch information
wsxiaoys authored Aug 30, 2023
1 parent 3526ca3 commit 054aefa
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,12 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-11]
os: [macos-11, ubuntu-latest]
include:
- os: macos-11
target: aarch64-apple-darwin
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu

env:
SCCACHE_GHA_ENABLED: true
Expand Down Expand Up @@ -101,16 +103,17 @@ jobs:
permissions:
contents: write
steps:
- name: Download a single artifact
- name: Download all artifacts
uses: actions/download-artifact@v3
with:
name: tabby_aarch64-apple-darwin

- name: Display structure of downloaded files
run: ls -R

- uses: ncipollo/release-action@v1
with:
allowUpdates: true
prerelease: true
name: "Development Build"
artifacts: tabby_aarch64-apple-darwin
artifacts: "tabby_*/tabby_*"
tag: latest
removeArtifacts: true
4 changes: 4 additions & 0 deletions ci/prepare_build_environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,7 @@
if [[ "$OSTYPE" == "darwin"* ]]; then
brew install protobuf
fi

if [[ "$OSTYPE" == "linux"* ]]; then
sudo apt-get -y install protobuf-compiler
fi
1 change: 1 addition & 0 deletions crates/tabby/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ use std::error::Error;
use vergen::EmitBuilder;

fn main() -> Result<(), Box<dyn Error>> {
// touch
EmitBuilder::builder().all_build().all_git().emit()?;
Ok(())
}

0 comments on commit 054aefa

Please sign in to comment.