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 "extra_pyinstaller_args" arg to freeze() #21

Closed
fredrikaverpil opened this issue Jun 1, 2018 · 1 comment
Closed

Add "extra_pyinstaller_args" arg to freeze() #21

fredrikaverpil opened this issue Jun 1, 2018 · 1 comment

Comments

@fredrikaverpil
Copy link
Contributor

fredrikaverpil commented Jun 1, 2018

I'm looking to pass extra arguments to pyinstaller for my main app.

Right now, I'm using a build.py script which I execute like so: python build.py freeze_all

In my freeze_all function, I have the fbs.builtin_commands.freeze function to build my main app. But the builtin_commands.freeze function does not accept any arguments. I'm noticing that that freeze_windows, freeze_mac, freeze_arch, freeze_linux already takes the extra_pyinstaller_args argument, but the fbs.builtin_commands.freeze function does not. So in my mind, a very quick fix for this would be to make the fbs.builtin_commands.freeze function accept a new extra_pyinstaller_args argument which would be passed on to the freeze_windows, freeze_mac, freeze_arch, freeze_linux functions.

I wouldn't mind whipping up a PR if you think it's a good idea.


The background to why I am looking to do this is I wish to add a hooks folder, which I ideally want placed in my project's root (not in src/main/python). I would then want to pass the --additional-hooks-dir as an extra pyinstaller argument when building the main app.

@fredrikaverpil
Copy link
Contributor Author

fredrikaverpil commented Jun 1, 2018

PR submitted.

This is so nice:

fbs.builtin_commands.freeze(extra_pyinstaller_args=['--log-level', 'DEBUG'])

And I can now choose if e.g. a commandline (main) application is showing its output :

fbs.builtin_commands.freeze(extra_pyinstaller_args=['--console'])

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

No branches or pull requests

1 participant