Add EXE build support and frozen-runtime path handling#60
Open
ryo08271154 wants to merge 1 commit intomainfrom
Open
Add EXE build support and frozen-runtime path handling#60ryo08271154 wants to merge 1 commit intomainfrom
ryo08271154 wants to merge 1 commit intomainfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
.exe.Description
app_paths.pywhich providesget_app_dir(),get_resource_dir()andensure_config_dir()to resolve write/read paths consistently for normal and frozen execution.build_exe.pyto build GUI (control.py) and CUI (voice_control.py) distributions using PyInstaller and to collect plugin modules as hidden imports viapkgutil.get_app_dir()/ensure_config_dir()sovoice_control.py,control.pyandedit_config.pyload and writeconfig/next to the executable at runtime.pkgutil.iter_modules()inplugin.pyand adjusted plugins (plugins/switchbot.py,plugins/watchlist.py) to useapp_pathsfor config/cookie file paths.README.mdand addedpyinstallertorequirements.txt.Testing
python -m py_compile app_paths.py build_exe.py voice_control.py control.py plugin.py edit_config.py plugins/watchlist.py plugins/switchbot.py, which completed successfully.Codex Task