toolboxv2 0.1.27__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- toolboxv2/__genv__.py +410 -0
- toolboxv2/__init__.py +384 -0
- toolboxv2/__main__.py +2584 -0
- toolboxv2/dist/favicon.ico +0 -0
- toolboxv2/dist/helper.html +1 -0
- toolboxv2/dist/helper.html.gz +0 -0
- toolboxv2/dist/hud.html +183 -0
- toolboxv2/dist/hud.html.gz +0 -0
- toolboxv2/dist/index.html +402 -0
- toolboxv2/dist/index.html.gz +0 -0
- toolboxv2/dist/main-15fe61ba.js +260 -0
- toolboxv2/dist/main-15fe61ba.js.gz +0 -0
- toolboxv2/dist/main-5d3f7ed2.js +47 -0
- toolboxv2/dist/main-5d3f7ed2.js.gz +0 -0
- toolboxv2/dist/main-603c0431.js +19 -0
- toolboxv2/dist/main-603c0431.js.gz +0 -0
- toolboxv2/dist/main-8e503b68.js +54 -0
- toolboxv2/dist/main-8e503b68.js.gz +0 -0
- toolboxv2/dist/vendors-d2eb5610.js +96 -0
- toolboxv2/dist/vendors-d2eb5610.js.gz +0 -0
- toolboxv2/dist/vendors-d30b95f6.js +19 -0
- toolboxv2/dist/vendors-d30b95f6.js.gz +0 -0
- toolboxv2/dist/web/0/WigetNav/navDrow.css +51 -0
- toolboxv2/dist/web/0/WigetNav/navDrow.css.gz +0 -0
- toolboxv2/dist/web/0/WigetNav/navDrow.html +16 -0
- toolboxv2/dist/web/0/WigetNav/navDrow.html.gz +0 -0
- toolboxv2/dist/web/0/WigetNav/navDrow.js +200 -0
- toolboxv2/dist/web/0/WigetNav/navDrow.js.gz +0 -0
- toolboxv2/dist/web/0/template.html +144 -0
- toolboxv2/dist/web/0/template.html.gz +0 -0
- toolboxv2/dist/web/0/welcome/welcome.css +326 -0
- toolboxv2/dist/web/0/welcome/welcome.css.gz +0 -0
- toolboxv2/dist/web/0/welcome/welcome.html +24 -0
- toolboxv2/dist/web/0/welcome/welcome.html.gz +0 -0
- toolboxv2/dist/web/0/welcome/welcome.js +165 -0
- toolboxv2/dist/web/0/welcome/welcome.js.gz +0 -0
- toolboxv2/dist/web/1/init0/tam.png +0 -0
- toolboxv2/dist/web/Drag/drag.css +23 -0
- toolboxv2/dist/web/Drag/drag.css.gz +0 -0
- toolboxv2/dist/web/Drag/drag.html +2 -0
- toolboxv2/dist/web/Drag/drag.js +220 -0
- toolboxv2/dist/web/Drag/drag.js.gz +0 -0
- toolboxv2/dist/web/assets/401.html +26 -0
- toolboxv2/dist/web/assets/401.html.gz +0 -0
- toolboxv2/dist/web/assets/404.html +202 -0
- toolboxv2/dist/web/assets/404.html.gz +0 -0
- toolboxv2/dist/web/assets/Wiget.css +118 -0
- toolboxv2/dist/web/assets/Wiget.css.gz +0 -0
- toolboxv2/dist/web/assets/backgrounds/TODO_loading_placeholder.txt +1 -0
- toolboxv2/dist/web/assets/backgrounds/dark-bg.png +0 -0
- toolboxv2/dist/web/assets/backgrounds/light-bg.png +0 -0
- toolboxv2/dist/web/assets/backgrounds/placeholder-loading_dark.gif +1 -0
- toolboxv2/dist/web/assets/backgrounds/placeholder-loading_light.gif +1 -0
- toolboxv2/dist/web/assets/loder/main.html +34 -0
- toolboxv2/dist/web/assets/loder/main.html.gz +0 -0
- toolboxv2/dist/web/assets/loder/styles.css +873 -0
- toolboxv2/dist/web/assets/loder/styles.css.gz +0 -0
- toolboxv2/dist/web/assets/login.html +437 -0
- toolboxv2/dist/web/assets/login.html.gz +0 -0
- toolboxv2/dist/web/assets/logout.html +1 -0
- toolboxv2/dist/web/assets/logout.html.gz +0 -0
- toolboxv2/dist/web/assets/m_log_in.html +1 -0
- toolboxv2/dist/web/assets/m_log_in.html.gz +0 -0
- toolboxv2/dist/web/assets/profile.html +0 -0
- toolboxv2/dist/web/assets/serverInWartung.html +20 -0
- toolboxv2/dist/web/assets/serverInWartung.html.gz +0 -0
- toolboxv2/dist/web/assets/signup.html +327 -0
- toolboxv2/dist/web/assets/signup.html.gz +0 -0
- toolboxv2/dist/web/assets/styles.css +0 -0
- toolboxv2/dist/web/assets/terms.html +32 -0
- toolboxv2/dist/web/assets/terms.html.gz +0 -0
- toolboxv2/dist/web/assets/waiting_list.html +150 -0
- toolboxv2/dist/web/assets/waiting_list.html.gz +0 -0
- toolboxv2/dist/web/assets/widgetControllerLogin.html +68 -0
- toolboxv2/dist/web/assets/widgetControllerLogin.html.gz +0 -0
- toolboxv2/dist/web/core0/Installer.html +80 -0
- toolboxv2/dist/web/core0/Installer.html.gz +0 -0
- toolboxv2/dist/web/core0/MainIdea.html +1 -0
- toolboxv2/dist/web/core0/MainIdea.html.gz +0 -0
- toolboxv2/dist/web/core0/ToolBoxInfos.html +176 -0
- toolboxv2/dist/web/core0/ToolBoxInfos.html.gz +0 -0
- toolboxv2/dist/web/core0/index.html +273 -0
- toolboxv2/dist/web/core0/index.html.gz +0 -0
- toolboxv2/dist/web/core0/installer.js +583 -0
- toolboxv2/dist/web/core0/installer.js.gz +0 -0
- toolboxv2/dist/web/core0/kontakt.html +26 -0
- toolboxv2/dist/web/core0/kontakt.html.gz +0 -0
- toolboxv2/dist/web/core0/roadmap.html +1 -0
- toolboxv2/dist/web/core0/roadmap.html.gz +0 -0
- toolboxv2/dist/web/dashboards/DynamicWidget.html +157 -0
- toolboxv2/dist/web/dashboards/DynamicWidget.html.gz +0 -0
- toolboxv2/dist/web/dashboards/dashboard.html +18 -0
- toolboxv2/dist/web/dashboards/dashboard.html.gz +0 -0
- toolboxv2/dist/web/dashboards/user_dashboard.html +348 -0
- toolboxv2/dist/web/dashboards/user_dashboard.html.gz +0 -0
- toolboxv2/dist/web/favicon.icns +0 -0
- toolboxv2/dist/web/favicon.ico +0 -0
- toolboxv2/dist/web/icons/128x128.png +0 -0
- toolboxv2/dist/web/icons/128x128@2x.png +0 -0
- toolboxv2/dist/web/icons/32x32.png +0 -0
- toolboxv2/dist/web/icons/Square107x107Logo.png +0 -0
- toolboxv2/dist/web/icons/Square142x142Logo.png +0 -0
- toolboxv2/dist/web/icons/Square150x150Logo.png +0 -0
- toolboxv2/dist/web/icons/Square284x284Logo.png +0 -0
- toolboxv2/dist/web/icons/Square30x30Logo.png +0 -0
- toolboxv2/dist/web/icons/Square310x310Logo.png +0 -0
- toolboxv2/dist/web/icons/Square44x44Logo.png +0 -0
- toolboxv2/dist/web/icons/Square71x71Logo.png +0 -0
- toolboxv2/dist/web/icons/Square89x89Logo.png +0 -0
- toolboxv2/dist/web/icons/StoreLogo.png +0 -0
- toolboxv2/dist/web/icons/icon.icns +0 -0
- toolboxv2/dist/web/icons/icon.ico +0 -0
- toolboxv2/dist/web/icons/icon.png +0 -0
- toolboxv2/dist/web/jsconfig.json +23 -0
- toolboxv2/dist/web/mainContent.html +764 -0
- toolboxv2/dist/web/mainContent.html.gz +0 -0
- toolboxv2/dist/web/package.json +19 -0
- toolboxv2/dist/web/pages/simplecore/collaboration.html +800 -0
- toolboxv2/dist/web/pages/simplecore/collaboration.html.gz +0 -0
- toolboxv2/dist/web/pages/simplecore/index.html +372 -0
- toolboxv2/dist/web/pages/simplecore/index.html.gz +0 -0
- toolboxv2/dist/web/pages/simplecore/innovation_tree.html +928 -0
- toolboxv2/dist/web/pages/simplecore/innovation_tree.html.gz +0 -0
- toolboxv2/dist/web/pages/simplecore/workbench.html +908 -0
- toolboxv2/dist/web/pages/simplecore/workbench.html.gz +0 -0
- toolboxv2/dist/web/robot.txt +0 -0
- toolboxv2/dist/web/scripts/AutoMarkdown.js +85 -0
- toolboxv2/dist/web/scripts/AutoMarkdown.js.gz +0 -0
- toolboxv2/dist/web/scripts/OverlayUtility.js +158 -0
- toolboxv2/dist/web/scripts/OverlayUtility.js.gz +0 -0
- toolboxv2/dist/web/scripts/WidgetUtility.js +485 -0
- toolboxv2/dist/web/scripts/WidgetUtility.js.gz +0 -0
- toolboxv2/dist/web/scripts/WorkerSocketRenderer.js +231 -0
- toolboxv2/dist/web/scripts/WorkerSocketRenderer.js.gz +0 -0
- toolboxv2/dist/web/scripts/cryp.js +452 -0
- toolboxv2/dist/web/scripts/cryp.js.gz +0 -0
- toolboxv2/dist/web/scripts/custom_auth.js +556 -0
- toolboxv2/dist/web/scripts/custom_auth.js.gz +0 -0
- toolboxv2/dist/web/scripts/emailWlist.js +119 -0
- toolboxv2/dist/web/scripts/emailWlist.js.gz +0 -0
- toolboxv2/dist/web/scripts/go_home.js +1 -0
- toolboxv2/dist/web/scripts/httpSender.js +231 -0
- toolboxv2/dist/web/scripts/httpSender.js.gz +0 -0
- toolboxv2/dist/web/scripts/infos.js +53 -0
- toolboxv2/dist/web/scripts/infos.js.gz +0 -0
- toolboxv2/dist/web/scripts/login.js +189 -0
- toolboxv2/dist/web/scripts/login.js.gz +0 -0
- toolboxv2/dist/web/scripts/m_link.js +126 -0
- toolboxv2/dist/web/scripts/m_link.js.gz +0 -0
- toolboxv2/dist/web/scripts/scripts.js +486 -0
- toolboxv2/dist/web/scripts/scripts.js.gz +0 -0
- toolboxv2/dist/web/scripts/singup.js +154 -0
- toolboxv2/dist/web/scripts/singup.js.gz +0 -0
- toolboxv2/dist/web/scripts/tauri/autoDetection.js +73 -0
- toolboxv2/dist/web/scripts/tauri/autoDetection.js.gz +0 -0
- toolboxv2/dist/web/scripts/tauri/localTb.js +72 -0
- toolboxv2/dist/web/scripts/tauri/localTb.js.gz +0 -0
- toolboxv2/dist/web/scripts/tauri/main_controler.js +80 -0
- toolboxv2/dist/web/scripts/tauri/main_controler.js.gz +0 -0
- toolboxv2/dist/web/scripts/tauri/widgetManager.js +27 -0
- toolboxv2/dist/web/scripts/tauri/widgetManager.js.gz +0 -0
- toolboxv2/dist/web/scripts/util.js +96 -0
- toolboxv2/dist/web/scripts/util.js.gz +0 -0
- toolboxv2/dist/web/sw.js +245 -0
- toolboxv2/dist/web/sw.js.gz +0 -0
- toolboxv2/dist/web/systemMSG/speech_balloon.css +128 -0
- toolboxv2/dist/web/systemMSG/speech_balloon.css.gz +0 -0
- toolboxv2/dist/web/systemMSG/speech_balloon.js +123 -0
- toolboxv2/dist/web/systemMSG/speech_balloon.js.gz +0 -0
- toolboxv2/dist/web/systemMSG/text.html +13 -0
- toolboxv2/dist/web/systemMSG/text.html.gz +0 -0
- toolboxv2/dist/web/webapp/TTTimg.png +0 -0
- toolboxv2/dist/web/webapp/black-button.png +0 -0
- toolboxv2/dist/web/webapp/bmc-logo.svg +16 -0
- toolboxv2/dist/web/webapp/bmc-logo.svg.gz +0 -0
- toolboxv2/dist/web/webapp/icon-1024.png +0 -0
- toolboxv2/dist/web/webapp/icon-192.png +0 -0
- toolboxv2/dist/web/webapp/icon-512.png +0 -0
- toolboxv2/dist/web/webapp/manifest.json +24 -0
- toolboxv2/dist/web/webapp/ogimg.png +0 -0
- toolboxv2/feature_loader.py +546 -0
- toolboxv2/feature_loader_registry.py +975 -0
- toolboxv2/features/core/.installed +0 -0
- toolboxv2/features/core/feature.yaml +70 -0
- toolboxv2/features/mini/feature.yaml +27 -0
- toolboxv2/features_packed/tbv2-feature-cli-0.1.27.zip +0 -0
- toolboxv2/features_packed/tbv2-feature-desktop-0.1.27.zip +0 -0
- toolboxv2/features_packed/tbv2-feature-exotic-0.1.27.zip +0 -0
- toolboxv2/features_packed/tbv2-feature-isaa-0.1.27.zip +0 -0
- toolboxv2/features_packed/tbv2-feature-web-0.1.27.zip +0 -0
- toolboxv2/features_packed/tbv2-feature-web.backup-0.1.27.zip +0 -0
- toolboxv2/flows/__init__.py +114 -0
- toolboxv2/flows/cli/__init__.py +0 -0
- toolboxv2/flows/cli/pyshell.py +603 -0
- toolboxv2/flows/idle.py +5 -0
- toolboxv2/flows/mini/__init__.py +0 -0
- toolboxv2/flows/mini/minicli.py +2425 -0
- toolboxv2/flows/mini/toolbox_admin.py +896 -0
- toolboxv2/mcp_server/__init__.py +111 -0
- toolboxv2/mcp_server/__main__.py +327 -0
- toolboxv2/mcp_server/flow_handlers.py +617 -0
- toolboxv2/mcp_server/flow_manager.py +842 -0
- toolboxv2/mcp_server/http_transport.py +441 -0
- toolboxv2/mcp_server/managers.py +568 -0
- toolboxv2/mcp_server/models.py +305 -0
- toolboxv2/mcp_server/server.py +842 -0
- toolboxv2/mcp_server/workers.py +1304 -0
- toolboxv2/mods/Canvas.py +3468 -0
- toolboxv2/mods/ChatModule.py +153 -0
- toolboxv2/mods/CloudM/AdminDashboard.py +2863 -0
- toolboxv2/mods/CloudM/Auth.py +116 -0
- toolboxv2/mods/CloudM/DashboardAPI.py +854 -0
- toolboxv2/mods/CloudM/LiveSync/__init__.py +387 -0
- toolboxv2/mods/CloudM/LiveSync/cli.py +413 -0
- toolboxv2/mods/CloudM/LiveSync/client.py +797 -0
- toolboxv2/mods/CloudM/LiveSync/config.py +126 -0
- toolboxv2/mods/CloudM/LiveSync/conflict.py +153 -0
- toolboxv2/mods/CloudM/LiveSync/crypto.py +191 -0
- toolboxv2/mods/CloudM/LiveSync/index.py +221 -0
- toolboxv2/mods/CloudM/LiveSync/minio_helper.py +301 -0
- toolboxv2/mods/CloudM/LiveSync/protocol.py +347 -0
- toolboxv2/mods/CloudM/LiveSync/server.py +662 -0
- toolboxv2/mods/CloudM/LogInSystem.py +669 -0
- toolboxv2/mods/CloudM/ModManager.py +5460 -0
- toolboxv2/mods/CloudM/RegistryServer.py +434 -0
- toolboxv2/mods/CloudM/UI/__init__.py +1 -0
- toolboxv2/mods/CloudM/UI/widget.py +100 -0
- toolboxv2/mods/CloudM/UserAccountManager.py +520 -0
- toolboxv2/mods/CloudM/UserDashboard.py +3528 -0
- toolboxv2/mods/CloudM/UserDataAPI.py +1237 -0
- toolboxv2/mods/CloudM/UserInstances.py +526 -0
- toolboxv2/mods/CloudM/__init__.py +18 -0
- toolboxv2/mods/CloudM/auth/AuthHelpers.py +243 -0
- toolboxv2/mods/CloudM/auth/__init__.py +7 -0
- toolboxv2/mods/CloudM/auth/api_config.py +28 -0
- toolboxv2/mods/CloudM/auth/api_magic_link.py +195 -0
- toolboxv2/mods/CloudM/auth/api_oauth.py +217 -0
- toolboxv2/mods/CloudM/auth/api_passkey.py +262 -0
- toolboxv2/mods/CloudM/auth/api_session.py +244 -0
- toolboxv2/mods/CloudM/auth/config.py +72 -0
- toolboxv2/mods/CloudM/auth/db_helpers.py +69 -0
- toolboxv2/mods/CloudM/auth/jwt_tokens.py +75 -0
- toolboxv2/mods/CloudM/auth/minio_policy.py +540 -0
- toolboxv2/mods/CloudM/auth/models.py +155 -0
- toolboxv2/mods/CloudM/auth/oauth.py +68 -0
- toolboxv2/mods/CloudM/auth/state.py +88 -0
- toolboxv2/mods/CloudM/auth/user_store.py +93 -0
- toolboxv2/mods/CloudM/email_services.py +400 -0
- toolboxv2/mods/CloudM/extras.py +447 -0
- toolboxv2/mods/CloudM/mini.py +144 -0
- toolboxv2/mods/CloudM/models.py +165 -0
- toolboxv2/mods/CloudM/module.py +235 -0
- toolboxv2/mods/CloudM/schemas.py +174 -0
- toolboxv2/mods/CloudM/types.py +43 -0
- toolboxv2/mods/CodeVerification.py +717 -0
- toolboxv2/mods/CounterTracker.py +1507 -0
- toolboxv2/mods/DB/__init__.py +10 -0
- toolboxv2/mods/DB/blob_instance.py +1201 -0
- toolboxv2/mods/DB/local_instance.py +148 -0
- toolboxv2/mods/DB/reddis_instance.py +203 -0
- toolboxv2/mods/DB/tb_adapter.py +346 -0
- toolboxv2/mods/DB/types.py +32 -0
- toolboxv2/mods/DB/ui.py +1035 -0
- toolboxv2/mods/DirCut/__init__.py +4 -0
- toolboxv2/mods/DirCut/module.py +2366 -0
- toolboxv2/mods/FileWidget.py +1008 -0
- toolboxv2/mods/MinimalHtml.py +169 -0
- toolboxv2/mods/P2PRPCClient.py +155 -0
- toolboxv2/mods/P2PRPCServer.py +178 -0
- toolboxv2/mods/PasswordManager.py +880 -0
- toolboxv2/mods/ProcessManager.py +70 -0
- toolboxv2/mods/SchedulerManager.py +615 -0
- toolboxv2/mods/SocketManager.py +1365 -0
- toolboxv2/mods/TTS.py +279 -0
- toolboxv2/mods/UltimateTTT.py +3611 -0
- toolboxv2/mods/WebSocketManager.py +662 -0
- toolboxv2/mods/WhatsAppTb/__init__.py +4 -0
- toolboxv2/mods/WhatsAppTb/client.py +1963 -0
- toolboxv2/mods/WhatsAppTb/module.py +55 -0
- toolboxv2/mods/WhatsAppTb/server.py +351 -0
- toolboxv2/mods/WhatsAppTb/utils.py +102 -0
- toolboxv2/mods/WidgetsProvider/StorageUtil.py +236 -0
- toolboxv2/mods/WidgetsProvider/__init__.py +6 -0
- toolboxv2/mods/WidgetsProvider/board_widget.py +169 -0
- toolboxv2/mods/WidgetsProvider/module.py +65 -0
- toolboxv2/mods/WidgetsProvider/types.py +16 -0
- toolboxv2/mods/__init__.py +4 -0
- toolboxv2/mods/cli_functions.py +612 -0
- toolboxv2/mods/talk.py +1627 -0
- toolboxv2/mods/welcome.py +635 -0
- toolboxv2/mods_dev/__init__.py +0 -0
- toolboxv2/node_modules/flatted/python/flatted.py +144 -0
- toolboxv2/node_modules/shell-quote/print.py +3 -0
- toolboxv2/setup_helper.py +783 -0
- toolboxv2/tests/a_util.py +258 -0
- toolboxv2/tests/conftest.py +81 -0
- toolboxv2/utils/__init__.py +34 -0
- toolboxv2/utils/brodcast/__init__.py +0 -0
- toolboxv2/utils/brodcast/client.py +43 -0
- toolboxv2/utils/brodcast/server.py +39 -0
- toolboxv2/utils/clis/__init__.py +0 -0
- toolboxv2/utils/clis/cli_input.py +121 -0
- toolboxv2/utils/clis/cli_jsx_server.py +639 -0
- toolboxv2/utils/clis/cli_mkdocs.py +486 -0
- toolboxv2/utils/clis/cli_oauth.py +107 -0
- toolboxv2/utils/clis/cli_printing.py +462 -0
- toolboxv2/utils/clis/cli_registry.py +1502 -0
- toolboxv2/utils/clis/cli_worker_manager.py +2279 -0
- toolboxv2/utils/clis/config_wizard.py +676 -0
- toolboxv2/utils/clis/db_cli_manager.py +1292 -0
- toolboxv2/utils/clis/docker_image_cli.py +355 -0
- toolboxv2/utils/clis/first_run.py +96 -0
- toolboxv2/utils/clis/llm_gateway_cli.py +550 -0
- toolboxv2/utils/clis/local_cli.py +577 -0
- toolboxv2/utils/clis/manifest_cli.py +1039 -0
- toolboxv2/utils/clis/observability_helper.py +516 -0
- toolboxv2/utils/clis/service_manager.py +898 -0
- toolboxv2/utils/clis/tauri_cli.py +1247 -0
- toolboxv2/utils/clis/tcm_p2p_cli.py +2185 -0
- toolboxv2/utils/clis/user_dashboard.py +1920 -0
- toolboxv2/utils/clis/user_manager.py +866 -0
- toolboxv2/utils/clis/venv_runner.py +974 -0
- toolboxv2/utils/daemon/__init__.py +7 -0
- toolboxv2/utils/daemon/daemon_app.py +8 -0
- toolboxv2/utils/daemon/daemon_util.py +271 -0
- toolboxv2/utils/extras/Style.py +756 -0
- toolboxv2/utils/extras/__init__.py +32 -0
- toolboxv2/utils/extras/base_widget.py +290 -0
- toolboxv2/utils/extras/blobs.py +1568 -0
- toolboxv2/utils/extras/code_analyzer/__init__.py +0 -0
- toolboxv2/utils/extras/code_analyzer/profiler.py +1447 -0
- toolboxv2/utils/extras/code_analyzer/tb_analyze.py +378 -0
- toolboxv2/utils/extras/code_analyzer/tb_analyze_runtime.py +1836 -0
- toolboxv2/utils/extras/code_analyzer/tb_analyze_static.py +2373 -0
- toolboxv2/utils/extras/code_analyzer/test_fixtures/__init__.py +0 -0
- toolboxv2/utils/extras/code_analyzer/test_fixtures/caller.py +13 -0
- toolboxv2/utils/extras/code_analyzer/test_fixtures/helpers.py +14 -0
- toolboxv2/utils/extras/db/__init__.py +0 -0
- toolboxv2/utils/extras/db/minio_helper.py +35 -0
- toolboxv2/utils/extras/db/minio_manager.py +1043 -0
- toolboxv2/utils/extras/db/mobile_db.py +944 -0
- toolboxv2/utils/extras/db/scoped_storage.py +1035 -0
- toolboxv2/utils/extras/depsy/__init__.py +0 -0
- toolboxv2/utils/extras/depsy/depmanager.py +601 -0
- toolboxv2/utils/extras/dev_runner.py +485 -0
- toolboxv2/utils/extras/fallback_tray.py +129 -0
- toolboxv2/utils/extras/gateway_live_client.py +838 -0
- toolboxv2/utils/extras/gist_control.py +91 -0
- toolboxv2/utils/extras/helper_test_functions.py +65 -0
- toolboxv2/utils/extras/install/__init__.py +0 -0
- toolboxv2/utils/extras/install/bsdiff_wrapper.py +461 -0
- toolboxv2/utils/extras/install/diff_uploader.py +314 -0
- toolboxv2/utils/extras/install/install_validator.py +562 -0
- toolboxv2/utils/extras/install/rollback_manager.py +483 -0
- toolboxv2/utils/extras/install/upload_cache.py +231 -0
- toolboxv2/utils/extras/install/zip_security.py +186 -0
- toolboxv2/utils/extras/live_debugger.py +173 -0
- toolboxv2/utils/extras/mkdocs.py +3772 -0
- toolboxv2/utils/extras/notification.py +1275 -0
- toolboxv2/utils/extras/pt_spinner_patch.py +111 -0
- toolboxv2/utils/extras/qr.py +23 -0
- toolboxv2/utils/extras/registry_client.py +2231 -0
- toolboxv2/utils/extras/reqbuilder.py +36 -0
- toolboxv2/utils/extras/show_and_hide_console.py +23 -0
- toolboxv2/utils/manifest/__init__.py +57 -0
- toolboxv2/utils/manifest/converter.py +474 -0
- toolboxv2/utils/manifest/loader.py +307 -0
- toolboxv2/utils/manifest/schema.py +815 -0
- toolboxv2/utils/manifest/service_manager.py +330 -0
- toolboxv2/utils/proxy/__init__.py +7 -0
- toolboxv2/utils/proxy/prox_util.py +173 -0
- toolboxv2/utils/proxy/proxy_app.py +8 -0
- toolboxv2/utils/security/__init__.py +3 -0
- toolboxv2/utils/security/cryp.py +536 -0
- toolboxv2/utils/singelton_class.py +15 -0
- toolboxv2/utils/system/Build.py +324 -0
- toolboxv2/utils/system/__init__.py +55 -0
- toolboxv2/utils/system/all_functions_enums.py +571 -0
- toolboxv2/utils/system/cache.py +59 -0
- toolboxv2/utils/system/ci/__init__.py +0 -0
- toolboxv2/utils/system/ci/ci_build.py +994 -0
- toolboxv2/utils/system/ci/ci_version.py +200 -0
- toolboxv2/utils/system/exe_bg.py +35 -0
- toolboxv2/utils/system/feature_manager.py +905 -0
- toolboxv2/utils/system/file_handler.py +1094 -0
- toolboxv2/utils/system/getting_and_closing_app.py +109 -0
- toolboxv2/utils/system/ipy_completer.py +75 -0
- toolboxv2/utils/system/main_tool.py +180 -0
- toolboxv2/utils/system/observability_adapter.py +253 -0
- toolboxv2/utils/system/openobserve_setup.py +523 -0
- toolboxv2/utils/system/session.py +610 -0
- toolboxv2/utils/system/state_system.py +433 -0
- toolboxv2/utils/system/tb_logger.py +1224 -0
- toolboxv2/utils/system/types.py +3424 -0
- toolboxv2/utils/toolbox.py +3044 -0
- toolboxv2/utils/workers/__init__.py +61 -0
- toolboxv2/utils/workers/config.py +636 -0
- toolboxv2/utils/workers/debug_runner.py +247 -0
- toolboxv2/utils/workers/event_manager.py +1546 -0
- toolboxv2/utils/workers/fast/__init__.py +0 -0
- toolboxv2/utils/workers/fast/demo_fast_tb.py +278 -0
- toolboxv2/utils/workers/fast/demo_fasttb_defaults.py +86 -0
- toolboxv2/utils/workers/fast/demo_fasttb_ws_sse.py +194 -0
- toolboxv2/utils/workers/fast/local_ui.py +1268 -0
- toolboxv2/utils/workers/fast/tray_api.py +467 -0
- toolboxv2/utils/workers/fast_tb.py +1169 -0
- toolboxv2/utils/workers/fast_tb_defaults.py +689 -0
- toolboxv2/utils/workers/fast_tb_handler.py +1192 -0
- toolboxv2/utils/workers/interface_registry.py +159 -0
- toolboxv2/utils/workers/server_worker.py +3372 -0
- toolboxv2/utils/workers/session.py +1078 -0
- toolboxv2/utils/workers/session_custom.py +299 -0
- toolboxv2/utils/workers/tauri_integration.py +426 -0
- toolboxv2/utils/workers/toolbox_integration.py +551 -0
- toolboxv2/utils/workers/upload_manager.py +395 -0
- toolboxv2/utils/workers/ws_bridge.py +386 -0
- toolboxv2/utils/workers/ws_worker.py +1035 -0
- toolboxv2/ytss.py +3265 -0
- toolboxv2-0.1.27.dist-info/METADATA +380 -0
- toolboxv2-0.1.27.dist-info/RECORD +425 -0
- toolboxv2-0.1.27.dist-info/WHEEL +5 -0
- toolboxv2-0.1.27.dist-info/entry_points.txt +2 -0
- toolboxv2-0.1.27.dist-info/licenses/AUTHORS.rst +13 -0
- toolboxv2-0.1.27.dist-info/licenses/LICENSE +18 -0
- toolboxv2-0.1.27.dist-info/top_level.txt +1 -0
toolboxv2/__genv__.py
ADDED
|
@@ -0,0 +1,410 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""
|
|
3
|
+
tb_env.py — ToolBoxV2 global PATH manager
|
|
4
|
+
Kompatibel mit installer.sh v1.0.0+ und installer.ps1 v1.0.0+
|
|
5
|
+
|
|
6
|
+
Erkennt & verwaltet:
|
|
7
|
+
Linux/macOS:
|
|
8
|
+
• installer.sh-Block (# ToolBoxV2 / TOOLBOX_HOME / PATH)
|
|
9
|
+
• Eigener Marker-Block (# >>> ToolBoxV2 PATH >>>)
|
|
10
|
+
• Symlinks in /usr/local/bin/tb, ~/.local/bin/tb
|
|
11
|
+
Windows:
|
|
12
|
+
• PATH-Eintrag (HKCU\\Environment\\PATH) — installer.ps1 & eigener
|
|
13
|
+
• TOOLBOX_HOME (HKCU\\Environment\\TOOLBOX_HOME) — installer.ps1
|
|
14
|
+
|
|
15
|
+
Usage:
|
|
16
|
+
python tb_env.py install
|
|
17
|
+
python tb_env.py uninstall
|
|
18
|
+
python tb_env.py status
|
|
19
|
+
"""
|
|
20
|
+
import sys, os, platform, re
|
|
21
|
+
|
|
22
|
+
# ── Basiswerte ────────────────────────────────────────────────────────────────
|
|
23
|
+
SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
|
|
24
|
+
SYSTEM = platform.system() # "Windows" | "Linux" | "Darwin"
|
|
25
|
+
BIN_DIR = os.path.join(SCRIPT_DIR, "Scripts" if SYSTEM == "Windows" else "bin")
|
|
26
|
+
|
|
27
|
+
# ── install.manifest Suchpfade ────────────────────────────────────────────────
|
|
28
|
+
_lad = os.environ.get("LOCALAPPDATA", "")
|
|
29
|
+
_app = os.environ.get("APPDATA", "")
|
|
30
|
+
|
|
31
|
+
MANIFEST_SEARCH = [
|
|
32
|
+
# Linux / macOS (installer.sh defaults)
|
|
33
|
+
"/opt/toolboxv2/install.manifest",
|
|
34
|
+
os.path.expanduser("~/.local/share/toolboxv2/install.manifest"),
|
|
35
|
+
os.path.expanduser("~/.toolboxv2/install.manifest"),
|
|
36
|
+
os.path.expanduser("~/Library/Application Support/toolboxv2/install.manifest"),
|
|
37
|
+
# Windows (installer.ps1 defaults)
|
|
38
|
+
os.path.join(_lad, "toolboxv2", "install.manifest") if _lad else "",
|
|
39
|
+
os.path.join(_app, "toolboxv2", "install.manifest") if _app else "",
|
|
40
|
+
r"C:\toolboxv2\install.manifest",
|
|
41
|
+
# Neben diesem Script (source-install direkt im repo)
|
|
42
|
+
os.path.join(SCRIPT_DIR, "install.manifest"),
|
|
43
|
+
]
|
|
44
|
+
|
|
45
|
+
# Symlink-Ziele des Installers (Linux/macOS)
|
|
46
|
+
INSTALLER_SYMLINKS = [
|
|
47
|
+
"/usr/local/bin/tb",
|
|
48
|
+
os.path.expanduser("~/.local/bin/tb"),
|
|
49
|
+
]
|
|
50
|
+
|
|
51
|
+
# Shell-Dateien (Linux/macOS)
|
|
52
|
+
SHELL_FILES = [
|
|
53
|
+
os.path.expanduser("~/.bashrc"),
|
|
54
|
+
os.path.expanduser("~/.zshrc"),
|
|
55
|
+
os.path.expanduser("~/.profile"),
|
|
56
|
+
]
|
|
57
|
+
|
|
58
|
+
# ── Marker (eigenes Format, Linux/macOS) ─────────────────────────────────────
|
|
59
|
+
MY_MARKER = "# >>> ToolBoxV2 PATH >>>"
|
|
60
|
+
MY_MARKER_END = "# <<< ToolBoxV2 PATH <<<"
|
|
61
|
+
MY_BLOCK = f"""{MY_MARKER}
|
|
62
|
+
export TOOLBOX_HOME="{SCRIPT_DIR}"
|
|
63
|
+
export PATH="{BIN_DIR}:$PATH"
|
|
64
|
+
{MY_MARKER_END}"""
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
# ── YAML mini-parser ──────────────────────────────────────────────────────────
|
|
68
|
+
def _yaml_get(path: str, key: str, default: str = "") -> str:
|
|
69
|
+
try:
|
|
70
|
+
for line in open(path, encoding="utf-8", errors="replace"):
|
|
71
|
+
m = re.match(rf'^{re.escape(key)}:\s*"?([^"\n]*)"?\s*$', line)
|
|
72
|
+
if m:
|
|
73
|
+
return m.group(1).strip()
|
|
74
|
+
except OSError:
|
|
75
|
+
pass
|
|
76
|
+
return default
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
def find_manifests() -> list[dict]:
|
|
80
|
+
results, seen = [], set()
|
|
81
|
+
# Auch TOOLBOX_HOME / TB_INSTALL_DIR aus aktueller Env prüfen
|
|
82
|
+
extra = [
|
|
83
|
+
os.path.join(os.environ.get("TOOLBOX_HOME", ""), "install.manifest"),
|
|
84
|
+
os.path.join(os.environ.get("TB_INSTALL_DIR", ""), "install.manifest"),
|
|
85
|
+
]
|
|
86
|
+
for mp in MANIFEST_SEARCH + extra:
|
|
87
|
+
if not mp:
|
|
88
|
+
continue
|
|
89
|
+
mp = os.path.normpath(mp)
|
|
90
|
+
if not os.path.isfile(mp) or mp in seen:
|
|
91
|
+
continue
|
|
92
|
+
seen.add(mp)
|
|
93
|
+
results.append({
|
|
94
|
+
"manifest_path": mp,
|
|
95
|
+
"toolbox_home": _yaml_get(mp, "toolbox_home"),
|
|
96
|
+
"bin_path": _yaml_get(mp, "bin_path"),
|
|
97
|
+
"install_mode": _yaml_get(mp, "install_mode"),
|
|
98
|
+
"tb_version": _yaml_get(mp, "tb_version"),
|
|
99
|
+
"runtime": _yaml_get(mp, "runtime"),
|
|
100
|
+
"installed_at": _yaml_get(mp, "installed_at"),
|
|
101
|
+
})
|
|
102
|
+
return results
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
# ══════════════════════════════════════════════════════════════════════════════
|
|
106
|
+
# WINDOWS — Registry-Helpers
|
|
107
|
+
# ══════════════════════════════════════════════════════════════════════════════
|
|
108
|
+
def _win_get_env(name: str) -> str:
|
|
109
|
+
import winreg
|
|
110
|
+
try:
|
|
111
|
+
key = winreg.OpenKey(winreg.HKEY_CURRENT_USER, "Environment", 0, winreg.KEY_READ)
|
|
112
|
+
val, _ = winreg.QueryValueEx(key, name)
|
|
113
|
+
winreg.CloseKey(key)
|
|
114
|
+
return val or ""
|
|
115
|
+
except FileNotFoundError:
|
|
116
|
+
return ""
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
def _win_set_env(name: str, value: str | None) -> None:
|
|
120
|
+
"""Setzt oder löscht (value=None) eine User-Umgebungsvariable."""
|
|
121
|
+
import winreg, ctypes
|
|
122
|
+
key = winreg.OpenKey(winreg.HKEY_CURRENT_USER, "Environment", 0, winreg.KEY_SET_VALUE)
|
|
123
|
+
if value is None:
|
|
124
|
+
try:
|
|
125
|
+
winreg.DeleteValue(key, name)
|
|
126
|
+
except FileNotFoundError:
|
|
127
|
+
pass
|
|
128
|
+
else:
|
|
129
|
+
winreg.SetValueEx(key, name, 0, winreg.REG_EXPAND_SZ, value)
|
|
130
|
+
winreg.CloseKey(key)
|
|
131
|
+
# WM_SETTINGCHANGE → laufende Shells übernehmen es sofort
|
|
132
|
+
ctypes.windll.user32.SendMessageTimeoutW(
|
|
133
|
+
0xFFFF, 0x001A, 0, "Environment", 0x0002, 5000, None
|
|
134
|
+
)
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
def _win_path_entries() -> list[str]:
|
|
138
|
+
return [p for p in _win_get_env("PATH").split(";") if p]
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
def _win_path_contains(entry: str) -> bool:
|
|
142
|
+
entry_norm = os.path.normcase(entry)
|
|
143
|
+
return any(os.path.normcase(p) == entry_norm for p in _win_path_entries())
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
def _win_path_add(entry: str) -> None:
|
|
147
|
+
parts = _win_path_entries()
|
|
148
|
+
_win_set_env("PATH", ";".join([entry] + parts))
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
def _win_path_remove(entries: list[str]) -> bool:
|
|
152
|
+
"""Entfernt alle Einträge aus der Liste. Gibt True zurück wenn etwas entfernt wurde."""
|
|
153
|
+
norm = {os.path.normcase(e) for e in entries}
|
|
154
|
+
parts = _win_path_entries()
|
|
155
|
+
filtered = [p for p in parts if os.path.normcase(p) not in norm]
|
|
156
|
+
if len(filtered) == len(parts):
|
|
157
|
+
return False
|
|
158
|
+
_win_set_env("PATH", ";".join(filtered))
|
|
159
|
+
return True
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
# ══════════════════════════════════════════════════════════════════════════════
|
|
163
|
+
# LINUX / MACOS — Shell-File-Helpers
|
|
164
|
+
# ══════════════════════════════════════════════════════════════════════════════
|
|
165
|
+
def _my_block_present(content: str) -> bool:
|
|
166
|
+
return MY_MARKER in content
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
def _installer_block_present(content: str) -> bool:
|
|
170
|
+
return bool(re.search(r'#\s*ToolBoxV2\s*\n\s*export TOOLBOX_HOME=', content))
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
def _remove_my_block(content: str) -> str:
|
|
174
|
+
lines, inside, out = content.splitlines(keepends=True), False, []
|
|
175
|
+
for line in lines:
|
|
176
|
+
if line.strip() == MY_MARKER:
|
|
177
|
+
inside = True
|
|
178
|
+
elif line.strip() == MY_MARKER_END:
|
|
179
|
+
inside = False
|
|
180
|
+
elif not inside:
|
|
181
|
+
out.append(line)
|
|
182
|
+
return "".join(out)
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
def _remove_installer_block(content: str) -> str:
|
|
186
|
+
return re.sub(
|
|
187
|
+
r'\n?[ \t]*#\s*ToolBoxV2\s*\n'
|
|
188
|
+
r'[ \t]*export TOOLBOX_HOME=[^\n]*\n'
|
|
189
|
+
r'[ \t]*export PATH=[^\n]*\n?',
|
|
190
|
+
'\n',
|
|
191
|
+
content,
|
|
192
|
+
)
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
def _symlink_status() -> list[tuple[str, str | None]]:
|
|
196
|
+
result = []
|
|
197
|
+
for sl in INSTALLER_SYMLINKS:
|
|
198
|
+
if os.path.islink(sl):
|
|
199
|
+
result.append((sl, os.readlink(sl)))
|
|
200
|
+
elif os.path.exists(sl):
|
|
201
|
+
result.append((sl, "(keine Symlink, reguläre Datei)"))
|
|
202
|
+
return result
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
# ══════════════════════════════════════════════════════════════════════════════
|
|
206
|
+
# ACTIONS
|
|
207
|
+
# ══════════════════════════════════════════════════════════════════════════════
|
|
208
|
+
def install() -> None:
|
|
209
|
+
if not os.path.isdir(BIN_DIR):
|
|
210
|
+
print(f"[ERROR] venv/bin nicht gefunden: {BIN_DIR}", file=sys.stderr)
|
|
211
|
+
sys.exit(1)
|
|
212
|
+
|
|
213
|
+
if SYSTEM == "Windows":
|
|
214
|
+
changed = False
|
|
215
|
+
# PATH
|
|
216
|
+
if _win_path_contains(BIN_DIR):
|
|
217
|
+
print(f"[SKIP] Bereits in PATH: {BIN_DIR}")
|
|
218
|
+
else:
|
|
219
|
+
_win_path_add(BIN_DIR)
|
|
220
|
+
print(f"[OK] PATH ← {BIN_DIR}")
|
|
221
|
+
changed = True
|
|
222
|
+
# TOOLBOX_HOME
|
|
223
|
+
current_home = _win_get_env("TOOLBOX_HOME")
|
|
224
|
+
if current_home and os.path.normcase(current_home) == os.path.normcase(SCRIPT_DIR):
|
|
225
|
+
print(f"[SKIP] TOOLBOX_HOME bereits gesetzt: {current_home}")
|
|
226
|
+
else:
|
|
227
|
+
_win_set_env("TOOLBOX_HOME", SCRIPT_DIR)
|
|
228
|
+
print(f"[OK] TOOLBOX_HOME ← {SCRIPT_DIR}")
|
|
229
|
+
changed = True
|
|
230
|
+
if changed:
|
|
231
|
+
print(" Neues Terminal öffnen um `tb` zu nutzen.")
|
|
232
|
+
else:
|
|
233
|
+
modified = []
|
|
234
|
+
for rc in SHELL_FILES:
|
|
235
|
+
if not os.path.exists(rc):
|
|
236
|
+
continue
|
|
237
|
+
content = open(rc).read()
|
|
238
|
+
if _installer_block_present(content):
|
|
239
|
+
print(f"[SKIP] installer.sh-Block gefunden in {rc} — kein Duplikat nötig")
|
|
240
|
+
continue
|
|
241
|
+
if _my_block_present(content):
|
|
242
|
+
print(f"[SKIP] Bereits eingetragen in {rc}")
|
|
243
|
+
continue
|
|
244
|
+
with open(rc, "a") as f:
|
|
245
|
+
f.write(f"\n{MY_BLOCK}\n")
|
|
246
|
+
modified.append(rc)
|
|
247
|
+
if modified:
|
|
248
|
+
print(f"[OK] Eingetragen in: {', '.join(modified)}")
|
|
249
|
+
print(" `source ~/.bashrc` ausführen oder Terminal neu starten.")
|
|
250
|
+
else:
|
|
251
|
+
print("[INFO] Bereits in allen Shell-Dateien vorhanden.")
|
|
252
|
+
|
|
253
|
+
|
|
254
|
+
def uninstall() -> None:
|
|
255
|
+
if SYSTEM == "Windows":
|
|
256
|
+
manifests = find_manifests()
|
|
257
|
+
|
|
258
|
+
# Alle bekannten TB-bin-Einträge sammeln (eigener + alle aus Manifests)
|
|
259
|
+
to_remove = [BIN_DIR]
|
|
260
|
+
for m in manifests:
|
|
261
|
+
if m["toolbox_home"]:
|
|
262
|
+
to_remove.append(os.path.join(m["toolbox_home"], "bin"))
|
|
263
|
+
if m["bin_path"]:
|
|
264
|
+
to_remove.append(os.path.dirname(m["bin_path"]))
|
|
265
|
+
|
|
266
|
+
removed = _win_path_remove(list(dict.fromkeys(to_remove))) # dedupliziert
|
|
267
|
+
if removed:
|
|
268
|
+
print("[OK] TB-Einträge aus User-PATH entfernt.")
|
|
269
|
+
else:
|
|
270
|
+
print("[INFO] Kein TB-Eintrag in PATH — nichts zu tun.")
|
|
271
|
+
|
|
272
|
+
# TOOLBOX_HOME entfernen (installer.ps1 setzt es, wir räumen es auf)
|
|
273
|
+
if _win_get_env("TOOLBOX_HOME"):
|
|
274
|
+
_win_set_env("TOOLBOX_HOME", None)
|
|
275
|
+
print("[OK] TOOLBOX_HOME aus User-Umgebung entfernt.")
|
|
276
|
+
else:
|
|
277
|
+
print("[INFO] TOOLBOX_HOME nicht gesetzt — nichts zu tun.")
|
|
278
|
+
|
|
279
|
+
if removed:
|
|
280
|
+
print(" Neues Terminal öffnen um Änderungen zu übernehmen.")
|
|
281
|
+
return
|
|
282
|
+
|
|
283
|
+
# Linux / macOS
|
|
284
|
+
modified = []
|
|
285
|
+
for rc in SHELL_FILES:
|
|
286
|
+
if not os.path.exists(rc):
|
|
287
|
+
continue
|
|
288
|
+
content = open(rc).read()
|
|
289
|
+
new = content
|
|
290
|
+
if _installer_block_present(new):
|
|
291
|
+
new = _remove_installer_block(new)
|
|
292
|
+
print(f"[OK] installer.sh-Block entfernt aus {rc}")
|
|
293
|
+
if _my_block_present(new):
|
|
294
|
+
new = _remove_my_block(new)
|
|
295
|
+
print(f"[OK] Eigener Marker-Block entfernt aus {rc}")
|
|
296
|
+
if new != content:
|
|
297
|
+
open(rc, "w").write(new)
|
|
298
|
+
modified.append(rc)
|
|
299
|
+
|
|
300
|
+
if not modified:
|
|
301
|
+
print("[INFO] Kein TB-Eintrag in Shell-Dateien gefunden.")
|
|
302
|
+
|
|
303
|
+
for sl, target in _symlink_status():
|
|
304
|
+
try:
|
|
305
|
+
os.remove(sl)
|
|
306
|
+
print(f"[OK] Symlink entfernt: {sl} → {target}")
|
|
307
|
+
except PermissionError:
|
|
308
|
+
print(f"[WARN] Kein Zugriff auf {sl} — ggf. sudo nötig")
|
|
309
|
+
|
|
310
|
+
if modified:
|
|
311
|
+
print(" Terminal neu starten um Änderungen zu übernehmen.")
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
def status() -> None:
|
|
315
|
+
W = 60
|
|
316
|
+
print("=" * W)
|
|
317
|
+
print(" ToolBoxV2 PATH Status")
|
|
318
|
+
print("=" * W)
|
|
319
|
+
|
|
320
|
+
# ── venv/bin ──────────────────────────────────────────────
|
|
321
|
+
print(f"\n[venv/bin]")
|
|
322
|
+
print(f" Pfad : {BIN_DIR}")
|
|
323
|
+
print(f" Existiert: {'ja' if os.path.isdir(BIN_DIR) else 'NEIN'}")
|
|
324
|
+
tb_bin = os.path.join(BIN_DIR, "tb.exe" if SYSTEM == "Windows" else "tb")
|
|
325
|
+
print(f" tb-Binary: {'ja' if os.path.isfile(tb_bin) else 'nicht gefunden'}")
|
|
326
|
+
|
|
327
|
+
# ── install.manifest ──────────────────────────────────────
|
|
328
|
+
manifests = find_manifests()
|
|
329
|
+
print(f"\n[Installer-Installationen ({len(manifests)} gefunden)]")
|
|
330
|
+
if manifests:
|
|
331
|
+
for m in manifests:
|
|
332
|
+
print(f" • {m['toolbox_home'] or '(unbekannt)'}")
|
|
333
|
+
print(f" Mode : {m['install_mode']}")
|
|
334
|
+
print(f" Version : {m['tb_version']}")
|
|
335
|
+
print(f" Runtime : {m['runtime']}")
|
|
336
|
+
print(f" Installiert: {m['installed_at']}")
|
|
337
|
+
print(f" Manifest : {m['manifest_path']}")
|
|
338
|
+
else:
|
|
339
|
+
print(" (keine install.manifest gefunden)")
|
|
340
|
+
|
|
341
|
+
if SYSTEM == "Windows":
|
|
342
|
+
# ── Windows PATH ──────────────────────────────────────
|
|
343
|
+
print(f"\n[Windows User-PATH]")
|
|
344
|
+
tb_entries = [p for p in _win_path_entries()
|
|
345
|
+
if "toolbox" in p.lower() or "toolbox" in p.lower()
|
|
346
|
+
or os.path.normcase(p) == os.path.normcase(BIN_DIR)]
|
|
347
|
+
if tb_entries:
|
|
348
|
+
for e in tb_entries:
|
|
349
|
+
src = ""
|
|
350
|
+
for m in manifests:
|
|
351
|
+
if m["toolbox_home"] and os.path.normcase(e) == os.path.normcase(
|
|
352
|
+
os.path.join(m["toolbox_home"], "bin")):
|
|
353
|
+
src = " ← installer.ps1"
|
|
354
|
+
if os.path.normcase(e) == os.path.normcase(BIN_DIR):
|
|
355
|
+
src += " ← tb_env.py"
|
|
356
|
+
print(f" [x] {e}{src}")
|
|
357
|
+
else:
|
|
358
|
+
print(" [ ] Kein TB-Eintrag gefunden")
|
|
359
|
+
|
|
360
|
+
# ── TOOLBOX_HOME ──────────────────────────────────────
|
|
361
|
+
print(f"\n[TOOLBOX_HOME (User-Env)]")
|
|
362
|
+
th = _win_get_env("TOOLBOX_HOME")
|
|
363
|
+
if th:
|
|
364
|
+
src = "← installer.ps1" if any(
|
|
365
|
+
m["toolbox_home"] and os.path.normcase(m["toolbox_home"]) == os.path.normcase(th)
|
|
366
|
+
for m in manifests
|
|
367
|
+
) else "← tb_env.py / manuell"
|
|
368
|
+
print(f" [x] {th} {src}")
|
|
369
|
+
else:
|
|
370
|
+
print(" [ ] nicht gesetzt")
|
|
371
|
+
|
|
372
|
+
else:
|
|
373
|
+
# ── Symlinks ──────────────────────────────────────────
|
|
374
|
+
print(f"\n[Symlinks]")
|
|
375
|
+
symlinks = _symlink_status()
|
|
376
|
+
if symlinks:
|
|
377
|
+
for sl, target in symlinks:
|
|
378
|
+
print(f" [x] {sl} → {target}")
|
|
379
|
+
else:
|
|
380
|
+
print(" (keine TB-Symlinks gefunden)")
|
|
381
|
+
|
|
382
|
+
# ── Shell-Dateien ─────────────────────────────────────
|
|
383
|
+
print(f"\n[Shell-Einträge]")
|
|
384
|
+
for rc in SHELL_FILES:
|
|
385
|
+
if not os.path.exists(rc):
|
|
386
|
+
continue
|
|
387
|
+
content = open(rc).read()
|
|
388
|
+
installer = _installer_block_present(content)
|
|
389
|
+
own = _my_block_present(content)
|
|
390
|
+
tag = ""
|
|
391
|
+
if installer: tag += "[installer.sh] "
|
|
392
|
+
if own: tag += "[tb_env.py]"
|
|
393
|
+
if not tag: tag = "[ ]"
|
|
394
|
+
print(f" {tag} {rc}")
|
|
395
|
+
|
|
396
|
+
print()
|
|
397
|
+
|
|
398
|
+
|
|
399
|
+
def main():
|
|
400
|
+
# ── Entry ─────────────────────────────────────────────────────────────────────
|
|
401
|
+
CMDS = {"install": install, "uninstall": uninstall, "status": status}
|
|
402
|
+
|
|
403
|
+
if len(sys.argv) != 2 or sys.argv[1] not in CMDS:
|
|
404
|
+
print(f"Usage: tb access [install|uninstall|status]")
|
|
405
|
+
sys.argv.append("status")
|
|
406
|
+
|
|
407
|
+
CMDS[sys.argv[1]]()
|
|
408
|
+
|
|
409
|
+
if __name__ == "__main__":
|
|
410
|
+
main()
|