Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add build of compiled python app on push to main branch #94

Merged
merged 2 commits into from Jul 28, 2022

Conversation

hdeadman
Copy link
Contributor

This adds an automated build of the compiled python code that can be downloaded and run, similar to a release zip. You can see an example of the build and download the artifact from: here

  • checks out code
  • installs dependencies (or downloads pip cache)
  • installs cx_Freeze
  • builds python executable
  • zips compiled files b/c uploading files individually was slow
  • uploads the zip as an artifact
  • people can download the artifact from the Actions tab

Maybe it's not that useful b/c users can't customize anything but at least it shows the build process.

This results in a zipped zip file which requires two unzips.
It is possible to upload all the 2000 files so that they are in one zipped artifact but it's painful to watch and takes about 4.5 minutes for that step to complete.

@zayKenyon
Copy link
Owner

zayKenyon commented Jul 23, 2022

I think this is really cool, I love automation like this.

However, as you already pointed out, we are zipping a zip which I know from experience @OwOHamper has very strong thoughts on :^) .

Honestly, the first zip file taking longer to upload is a bummer, but I think we can get away with that considering most of our downloads come from the status message and Discord announcement; which we have complete control over the time of their release.

My first actual issue is that users have to download it from the Actions tab, we already struggle with directing users to downloading from Releases as most of our users are seemingly Git-newbs. Yet, perhaps this could be solved by redirecting users there from the README #releases anchor?

- checks out code
- installs dependencies (or downloads pip cache)
- installs cx_Freeze
- builds python executable
- uploads compiled folder as artifact

People can download the zipped artifact from the build action.
@hdeadman
Copy link
Contributor Author

I changed it to just upload the folder of compiled files so it downloads as a single zip. I also took a stab at a section for the readme. I describe a workflow that isn't really realistic for most changes (e.g. you would want to clone the repo locally to work on it) but it would let someone make a small tweak in the browser and get a compiled app to run. If you think it will just cause confusion to bring attention to it, it could be left out.

@zayKenyon zayKenyon requested a review from OwOHamper July 26, 2022 00:45
@zayKenyon
Copy link
Owner

LGTM!

@zayKenyon zayKenyon merged commit 716ebae into zayKenyon:main Jul 28, 2022
@OwOHamper
Copy link
Collaborator

@hdeadman Would it be possible to use actual compression upon generation of the .zip file? Currently it is same size as it is unzipped

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.

None yet

3 participants