Skip to content

Commit

Permalink
fix ci again
Browse files Browse the repository at this point in the history
  • Loading branch information
jiacai2050 committed Jan 1, 2025
1 parent 27da99c commit 3dd03fe
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/build-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ for target in "${targets[@]}"; do
dst_dir=zig-out/${filename}

# 1. Build
if [[ "${target}" == "x86_64" ]];then
if [[ "${target}" == "x86_64-linux" ]];then
zig build -Doptimize=ReleaseSafe -p ${dst_dir} \
-Dgit_commit=${GIT_COMMIT} -Dbuild_date=${BUILD_DATE}
else
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,4 +72,4 @@ jobs:
sudo apt update && sudo apt-get install -y libcurl4-openssl-dev
- name: Build
run: |
zig build -Dtarget=${{ matrix.targets }}
zig build -Dtarget=${{ matrix.targets }} -Dskip_zigfetch=true
8 changes: 7 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ on:
tags:
- "v*"


concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: write

Expand All @@ -35,14 +40,15 @@ jobs:
- name: Set env
run: |
echo "RELEASE_VERSION=${{ github.ref_name }}" >> $GITHUB_ENV
echo "OUT_DIR=/tmp/zigcli-${{ github.ref_name }}" >> $GITHUB_ENV
echo "OUT_DIR=/tmp/zigcli" >> $GITHUB_ENV
- name: Build(Ubuntu)
if: matrix.os == 'ubuntu-latest'
run: |
bash .github/build-release.sh
- name: Build(MacOS)
if: matrix.os == 'macos-latest'
run: |
mkdir -p "${OUT_DIR}"
zig build -Doptimize=ReleaseSafe \
-Dgit_commit=${GIT_COMMIT} -Dbuild_date=${BUILD_DATE}
rm -f zig-out/bin/*demo
Expand Down
4 changes: 2 additions & 2 deletions docs/content/_index.org
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#+TITLE: Zigcli
#+DATE: 2023-10-21T12:09:48+0800
#+LASTMOD: 2024-08-17T18:53:40+0800
#+LASTMOD: 2025-01-01T17:52:56+0800
#+TYPE: docs
#+author: Jiacai Liu

[[https://github.com/jiacai2050/zigcli][https://img.shields.io/github/stars/jiacai2050/zigcli.svg]]
[[https://github.com/jiacai2050/loc/actions/workflows/CI.yml][https://github.com/jiacai2050/loc/actions/workflows/CI.yml/badge.svg]]
[[https://github.com/jiacai2050/loc/actions/workflows/binary.yml][https://github.com/jiacai2050/loc/actions/workflows/binary.yml/badge.svg]]
[[https://github.com/jiacai2050/loc/actions/workflows/binary.yml][https://github.com/jiacai2050/loc/actions/workflows/release.yml/badge.svg]]
[[https://img.shields.io/badge/zig%20version-0.13.0-blue.svg]]

#+begin_quote
Expand Down

0 comments on commit 3dd03fe

Please sign in to comment.