Skip to content

Commit

Permalink
ci: add compile_herolib.sh, use it to make sure it keeps working (rel…
Browse files Browse the repository at this point in the history
…ated #23467) (#23469)
  • Loading branch information
felipensp authored Jan 15, 2025
1 parent f83ea1b commit e0303b2
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/compile_herolib.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
#!/usr/bin/env bash

set -e

function show() {
printf "\u001b[35m$1\u001b[0m\n"
}

rm -rf herolib/

show "Clone https://github.com/freeflowuniverse/herolib"
v retry -- git clone --filter=blob:none --quiet https://github.com/freeflowuniverse/herolib herolib
cd herolib
git checkout development

mkdir -p ~/.vmodules/freeflowuniverse
ln -s $(pwd)/lib ~/.vmodules/freeflowuniverse/herolib
cd cli

show "Checkout last known good commit"
git checkout fa0dac57ec218c0d65e0e8d5bba45ba2fd28d3d7

v wipe-cache
show "Build project no parallel (gcc)"
v -cc gcc -cg -enable-globals -w -n hero.v
show "Checking build"
ls -l ./hero

v wipe-cache
show "Build project no parallel (clang)"
v -cc clang -cg -enable-globals -w -n hero.v
show "Checking build"
ls -l ./hero

v wipe-cache
show "Build project with -parallel-cc (clang)"
v -cc clang -cg -enable-globals -parallel-cc -w -n hero.v
show "Checking gcc build"
ls -l ./hero

v wipe-cache
show "Build project with -parallel-cc (gcc)"
v -cc gcc -cg -enable-globals -parallel-cc -w -n hero.v
show "Checking clang build"
ls -l ./hero

rm -rf ../../herolib
3 changes: 3 additions & 0 deletions .github/workflows/v_apps_and_modules_compile_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ jobs:
- name: Test discord.v
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: .github/workflows/compile_discordv.sh
- name: Build herolib
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: .github/workflows/compile_herolib.sh
- name: Build vlang/vab
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
run: |
Expand Down

0 comments on commit e0303b2

Please sign in to comment.