diff options
Diffstat (limited to 'Justfile')
| -rw-r--r-- | Justfile | 57 |
1 files changed, 43 insertions, 14 deletions
@@ -3,7 +3,10 @@ # Justfile for Fedora Linux + Pebble SDK 4.9+ (2026) # ============================================= -emulator := "basalt" +# Default emulator: gabbro = Pebble Round 2 (new hardware, 260×260 round display) +# Use 'just dev-basalt' / 'just debug-dev-basalt' for the older rectangular display. +emulator := "gabbro" +emulator_old := "basalt" # Default: show all available commands default: @@ -26,29 +29,42 @@ alias k := kill build: pebble build -# Install to the basalt emulator (this also starts the emulator if it's not running) +# Install to the gabbro emulator (Pebble Round 2) install: pebble install --emulator {{emulator}} -# Build + Install (the command you will use most often) +# Build + install on Pebble Round 2 (gabbro) — primary target # Kills any stale emulator first so install never races against the boot animation. dev: -pebble kill pebble build && pebble install --emulator {{emulator}} +# Build + install on old rectangular display (basalt) +dev-basalt: + -pebble kill + pebble build && pebble install --emulator {{emulator_old}} + # Show live logs (run this in a **second** terminal) logs: pebble logs --emulator {{emulator}} +# Show live logs for basalt emulator +logs-basalt: + pebble logs --emulator {{emulator_old}} + # Take a screenshot of the emulator screenshot: pebble screenshot --emulator {{emulator}} +# Take a screenshot of the basalt emulator +screenshot-basalt: + pebble screenshot --emulator {{emulator_old}} + # ───────────────────────────────────────────── # Emulator control # ───────────────────────────────────────────── -# Kill / stop the running emulator (this is the fixed command) +# Kill / stop the running emulator kill: pebble kill @@ -56,14 +72,20 @@ kill: # Emulator recovery # ───────────────────────────────────────────── -# Reset the basalt SPI flash to factory state. +# Reset the gabbro SPI flash to factory state. # Use this when 'just dev' hangs on the Pebble boot screen — it means the # flash was corrupted (e.g. by killing multiple concurrent qemu processes). reset-flash: -pebble kill - bunzip2 -k -c ~/.pebble-sdk/SDKs/4.9.148/sdk-core/pebble/basalt/qemu/qemu_spi_flash.bin.bz2 > ~/.pebble-sdk/4.9.148/basalt/qemu_spi_flash.bin + bunzip2 -k -c ~/.pebble-sdk/SDKs/4.9.148/sdk-core/pebble/gabbro/qemu/qemu_spi_flash.bin.bz2 > ~/.pebble-sdk/4.9.148/gabbro/qemu_spi_flash.bin @echo "Flash reset to factory state. Run 'just dev' to reinstall." +# Reset the basalt SPI flash to factory state. +reset-flash-basalt: + -pebble kill + bunzip2 -k -c ~/.pebble-sdk/SDKs/4.9.148/sdk-core/pebble/basalt/qemu/qemu_spi_flash.bin.bz2 > ~/.pebble-sdk/4.9.148/basalt/qemu_spi_flash.bin + @echo "Flash reset to factory state. Run 'just dev-basalt' to reinstall." + # ───────────────────────────────────────────── # Maintenance commands # ───────────────────────────────────────────── @@ -89,22 +111,27 @@ test: debug-build: DEBUG=1 pebble build -# Build + install debug app +# Build + install debug app on Pebble Round 2 (gabbro) # Kills any stale emulator first (same reason as dev). debug-dev: -pebble kill DEBUG=1 pebble build && pebble install --emulator {{emulator}} +# Build + install debug app on old rectangular display (basalt) +debug-dev-basalt: + -pebble kill + DEBUG=1 pebble build && pebble install --emulator {{emulator_old}} + # ───────────────────────────────────────────── # Debug / Testing helpers # ───────────────────────────────────────────── # Build, install, and remind you to open logs dev-with-logs: - @echo "✅ Building and installing..." + @echo "Building and installing..." just dev @echo "" - @echo "🚀 Now open a second terminal and run: just logs" + @echo "Now open a second terminal and run: just logs" # Show current SDK version sdk-version: @@ -113,10 +140,12 @@ sdk-version: # Help / reminder help: @echo "FastForge development commands:" - @echo " just dev → build + install (most used)" - @echo " just logs → live logs (second terminal)" - @echo " just kill → stop the emulator" - @echo " just clean → remove build files" - @echo " just rebuild → clean + dev" + @echo " just dev → build + install on Round 2/gabbro (primary)" + @echo " just dev-basalt → build + install on old basalt display" + @echo " just logs → live logs for gabbro (second terminal)" + @echo " just logs-basalt → live logs for basalt (second terminal)" + @echo " just kill → stop the emulator" + @echo " just clean → remove build files" + @echo " just rebuild → clean + dev" @echo "" @echo "Run 'just' to see all available commands." |
