Skip to content

Commit

Permalink
chore(ci): cargo build with -Zgitoxide (#12504)
Browse files Browse the repository at this point in the history
  • Loading branch information
everpcpc committed Aug 18, 2023
1 parent b625033 commit 10d437d
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions .github/actions/build_linux/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ runs:
if: env.BUILD_PROFILE == 'debug' && inputs.artifacts == 'all'
shell: bash
run: |
cargo build --target ${{ inputs.target }} --features ${{ inputs.features }}
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --features ${{ inputs.features }}
ls -lh ./target/${{ inputs.target }}/${{ env.BUILD_PROFILE }}/databend-*
- name: Build Debug for specific artifacts
Expand All @@ -77,7 +77,7 @@ runs:
artifacts="${{ inputs.artifacts }}"
for artifact in ${artifacts//,/ }; do
echo "==> building databend-$artifact ..."
cargo build --target ${{ inputs.target }} --features ${{ inputs.features }} --bin databend-$artifact
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --features ${{ inputs.features }} --bin databend-$artifact
ls -lh ./target/${{ inputs.target }}/${{ env.BUILD_PROFILE }}/databend-$artifact
done
Expand All @@ -88,7 +88,7 @@ runs:
artifacts="meta,metactl,query,sqllogictests"
for artifact in ${artifacts//,/ }; do
echo "==> building databend-$artifact ..."
cargo build --target ${{ inputs.target }} --features ${{ inputs.features }} --release --bin databend-$artifact
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --features ${{ inputs.features }} --release --bin databend-$artifact
ls -lh ./target/${{ inputs.target }}/${{ env.BUILD_PROFILE }}/databend-$artifact
done
Expand All @@ -99,7 +99,7 @@ runs:
artifacts="${{ inputs.artifacts }}"
for artifact in ${artifacts//,/ }; do
echo "==> building databend-$artifact ..."
cargo build --target ${{ inputs.target }} --features ${{ inputs.features }} --release --bin databend-$artifact
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --features ${{ inputs.features }} --release --bin databend-$artifact
ls -lh ./target/${{ inputs.target }}/${{ env.BUILD_PROFILE }}/databend-$artifact
done
Expand Down
10 changes: 5 additions & 5 deletions .github/actions/build_macos/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,18 @@ runs:
- name: Build Debug for all artifacts
if: env.BUILD_PROFILE == 'debug' && inputs.artifacts == 'all'
shell: bash
run: cargo build --target ${{ inputs.target }}
run: cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }}

- name: Build Debug for specific artifacts
if: env.BUILD_PROFILE == 'debug' && inputs.artifacts != 'all'
shell: bash
run: |
artifacts="${{ inputs.artifacts }}"
echo "==> building libs ..."
cargo build --target ${{ inputs.target }} --lib
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --lib
for artifact in ${artifacts//,/ }; do
echo "==> building databend-$artifact ..."
cargo build --target ${{ inputs.target }} --bin databend-$artifact
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --bin databend-$artifact
done
- name: Build Release
Expand All @@ -61,10 +61,10 @@ runs:
run: |
artifacts="${{ inputs.artifacts }}"
echo "==> building libs ..."
cargo build --target ${{ inputs.target }} --release --lib
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --release --lib
for artifact in ${artifacts//,/ }; do
echo "==> building databend-$artifact ..."
cargo build --target ${{ inputs.target }} --release --bin databend-$artifact
cargo -Zgitoxide=fetch,shallow-index,shallow-deps build --target ${{ inputs.target }} --release --bin databend-$artifact
done
- name: Upload artifact
Expand Down
2 changes: 1 addition & 1 deletion .github/actions/check/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ runs:

- name: Clippy
shell: bash
run: cargo clippy --workspace --all-targets --all-features -- -D warnings
run: cargo -Zgitoxide=fetch,shallow-index,shallow-deps clippy --workspace --all-targets --all-features -- -D warnings
4 changes: 2 additions & 2 deletions .github/actions/test_unit/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ runs:
bypass_env_vars: RUSTFLAGS,RUSTDOCFLAGS,RUST_TEST_THREADS,RUST_LOG,RUST_BACKTRACE

- shell: bash
run: cargo test
run: cargo -Zgitoxide=fetch,shallow-index,shallow-deps test
env:
RUST_TEST_THREADS: "2"
RUST_TEST_THREADS: "8"
RUST_LOG: ERROR
# RUST_BACKTRACE: full

Expand Down

1 comment on commit 10d437d

@vercel
Copy link

@vercel vercel bot commented on 10d437d Aug 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

databend – ./

databend.vercel.app
databend-git-main-databend.vercel.app
databend.rs
databend-databend.vercel.app

Please sign in to comment.