Add installer GUI and file system access feature
This commit introduces a new Tkinter-based GUI installer script (`installer/main.py`) that manages file extraction and shortcut creation. Additionally, a new file system access feature was added to the `ToolboxWindow` class, allowing users to open directories with platform-specific commands. Improvements also include platform-specific adjustments for Windows executables in the CMake configuration.
This commit is contained in:
20
installer/coder.py
Normal file
20
installer/coder.py
Normal file
@@ -0,0 +1,20 @@
|
||||
import base64
|
||||
|
||||
|
||||
def encode_file_to_base64(file_path):
|
||||
with open(file_path, 'rb') as file:
|
||||
return base64.b64encode(file.read()).decode('utf-8')
|
||||
|
||||
|
||||
# Base64-kodierte Strings generieren
|
||||
exe_base64 = encode_file_to_base64("D:/Repos/toolbox/cmake-build-release-visual-studio/Toolbox.exe")
|
||||
icon_base64 = encode_file_to_base64("D:/Repos/toolbox/cmake-build-release-visual-studio/toolbox.ico")
|
||||
|
||||
# Base64-Strings in Textdateien schreiben
|
||||
with open("Toolbox_exe_base64.txt", 'w') as exe_file:
|
||||
exe_file.write(exe_base64)
|
||||
|
||||
with open("Toolbox_icon_base64.txt", 'w') as icon_file:
|
||||
icon_file.write(icon_base64)
|
||||
|
||||
print("Base64-Daten erfolgreich in Textdateien gespeichert.")
|
||||
Reference in New Issue
Block a user