Skip to content

Commit

Permalink
chore: remove subdirectory in linux releases (#300)
Browse files Browse the repository at this point in the history
* remove subdirectory in linux releases

* fix typo
  • Loading branch information
Vritra4 authored Nov 7, 2024
1 parent 1e91f79 commit f7a3f0e
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 26 deletions.
26 changes: 12 additions & 14 deletions .github/workflows/build-linux-amd64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,31 +37,29 @@ jobs:
export GOARCH=${GOARCH}
export GOOS=${GOOS}
make build-linux-with-shared-library
pushd build
mkdir -p initia_${VERSION}
mv libmovevm.so initia_${VERSION}/libmovevm.${ARCH_NAME}.so
mv libcompiler.so initia_${VERSION}/libcompiler.${ARCH_NAME}.so
mv initiad initia_${VERSION}/
tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz initia_${VERSION}
popd
mkdir -p release-${GOOS}-${ARCH_NAME}
mv ./build/libmovevm.so ./release-${GOOS}-${ARCH_NAME}/libmovevm.${ARCH_NAME}.so
mv ./build/libcompiler.so ./release-${GOOS}-${ARCH_NAME}/libcompiler.${ARCH_NAME}.so
mv ./build/initiad ./release-${GOOS}-${ARCH_NAME}/initiad
tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz -C release-${GOOS}-${ARCH_NAME} initiad libmovevm.${ARCH_NAME}.so libcompiler.${ARCH_NAME}.so
make clean
- name: Static Build for Linux AMD64
run: |
export GOARCH=${GOARCH}
export GOOS=${GOOS}
make build-linux
pushd build
mkdir -p initia_${VERSION}_static
mv initiad initia_${VERSION}_static/
tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}_static.tar.gz initia_${VERSION}_static
popd
mkdir -p release-${GOOS}-${ARCH_NAME}-static
mv ./build/initiad ./release-${GOOS}-${ARCH_NAME}-static/initiad
tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}_static.tar.gz -C release-${GOOS}-${ARCH_NAME}-static initiad
make clean
- name: Release
uses: softprops/action-gh-release@v2
with:
files: |
./build/initia_${{ env.VERSION }}_Linux_${{ env.ARCH_NAME }}.tar.gz
./build/initia_${{ env.VERSION }}_Linux_${{ env.ARCH_NAME }}_static.tar.gz
./initia_${{ env.VERSION }}_Linux_${{ env.ARCH_NAME }}.tar.gz
./initia_${{ env.VERSION }}_Linux_${{ env.ARCH_NAME }}_static.tar.gz
env:
Version: ${{ env.VERSION }}
ARCH_NAME: ${{ env.ARCH_NAME }}
17 changes: 5 additions & 12 deletions .github/workflows/build-linux-arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,18 +52,11 @@ jobs:
docker rm temp
# Package the artifacts
cd ./build
mkdir -p initia_${VERSION}
mv initiad initia_${VERSION}/
mv libmovevm.so initia_${VERSION}/libmovevm.${ARCH_NAME}.so
mv libcompiler.so initia_${VERSION}/libcompiler.${ARCH_NAME}.so
tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz initia_${VERSION}
mv initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz ../
# Check the build result
cd ..
ls -l
file initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz
mkdir -p release-${GOOS}-${ARCH_NAME}
mv ./build/initiad ./release-${GOOS}-${ARCH_NAME}/initiad
mv ./build/libmovevm.so ./release-${GOOS}-${ARCH_NAME}/libmovevm.${ARCH_NAME}.so
mv ./build/libcompiler.so ./release-${GOOS}-${ARCH_NAME}/libcompiler.${ARCH_NAME}.so
tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz -C ./release-${GOOS}-${ARCH_NAME} initiad libmovevm.${ARCH_NAME}.so libcompiler.${ARCH_NAME}.so
# Remove the builder
docker buildx rm arm64-builder
Expand Down

0 comments on commit f7a3f0e

Please sign in to comment.