Skip to content

Commit e55de30

Browse files
sbryngelsonclaude
andcommitted
Print cache hit/miss status in HPC build cache setup
Reports whether existing build artifacts were found in the persistent cache directory, along with the last build timestamp. Helps diagnose whether Phoenix and Frontier runners are getting cache hits. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 491b27b commit e55de30

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

.github/scripts/setup-build-cache.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,13 @@ fi
3636
ln -s "$_cache_dir" "build"
3737

3838
echo " Symlink: build -> $_cache_dir"
39+
40+
# Report cache hit/miss based on whether compiled artifacts exist
41+
_cache_sim=$(find "$_cache_dir" -name 'simulation' -type f 2>/dev/null | head -1)
42+
if [ -n "$_cache_sim" ]; then
43+
_cache_age=$(stat -c '%y' "$_cache_sim" 2>/dev/null || stat -f '%Sm' "$_cache_sim" 2>/dev/null || echo "unknown")
44+
echo " Cache status: HIT (found existing build artifacts, last built: $_cache_age)"
45+
else
46+
echo " Cache status: MISS (no existing build artifacts)"
47+
fi
3948
echo "========================="

0 commit comments

Comments
 (0)