Skip to content

Project bundle build process#10

Open
relic-se wants to merge 7 commits into
RetiredWizard:mainfrom
relic-se:bundle
Open

Project bundle build process#10
relic-se wants to merge 7 commits into
RetiredWizard:mainfrom
relic-se:bundle

Conversation

@relic-se

@relic-se relic-se commented Jan 2, 2026

Copy link
Copy Markdown

This update adds a basic project bundling system which automatically copies necessary application files and installs the latest version of libraries into a zip file. Github workflows have also been added to do this automatically for each release. In order for this to work, writable actions will need to be allowed on the repository.

The also make the following changes to code.py:

  • Use adafruit_imageload library instead of OnDiskBitmap for better performance at the cost of RAM utilization (shouldn't be a problem for the Fruit Jam)
  • Automatically include bundled libraries if installed within Fruit Jam OS (fixes libraries which aren't included within Fruit Jam OS from throwing errors)
  • Removes library and image loading checks and assumes that everything is installed properly (I think it's better to error out if we have a bad installation)

@RetiredWizard

Copy link
Copy Markdown
Owner

I have resisted digging too deep into build/github automations but I'll spend some time looking at this to decide if it's really something I should be afraid of.

I do think these code.py changes make sense. I was surprised and it was kind of interesting when I had some corrupted files and ended up without the bitmaps loaded but the game still ran. But you're probably right, it would be better to error out in that case.

Would it be a problem to split out the code.py changes from the build system and submit them as a separate PR?

@relic-se

relic-se commented Jan 3, 2026

Copy link
Copy Markdown
Author

Yes, I can split these changes up. I'll push out separate PRs for the loading checks and the imageload process when I get the chance.

@relic-se

relic-se commented Jan 3, 2026

Copy link
Copy Markdown
Author

I've moved over the adafruit_imageload update to #18 and rebased this branch to remove that commit. As for the other two code.py updates, I think it makes sense to keep those changes in this PR because they're closely related to the bundling process.

This update does still keep adafruit_imageload in requirements.txt although it isn't exactly necessary in the current state of the main branch, but I think that doesn't hurt.

@relic-se

relic-se commented Jan 3, 2026

Copy link
Copy Markdown
Author

Btw, if you want to see exactly what the action workflows will do, you can install prerequisites using pip install circup requests (you probably already have these) and then run the build process using python build/build.py. The project bundle will then be located at dist/pac-fruitjam.zip.

All the .github/workflows/release_gh.yml workflow is doing is just that process whenever a new release is created and then uploads the zipped file to the release assets. This will be really helpful when it comes to adding this game to Fruit_Jam_Library as it helps resolve any potential library dependency issues.

Once we've gone through all of these updates, I recommend creating a first release to see how it goes and make it easier to share going forward.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants