A simple plugin to ease developing (web) tools
The plugin is developed and tested with PowerToys
v0.87.0
.
- Install PowerToys
- Exit PowerToys
- Download the
.zip
file applicable for your platform from the releases: - Extract it to:
%LocalAppData%\Microsoft\PowerToys\PowerToys Run\Plugins\ToolDevHelpers
- Start PowerToys
Alternatively you can use the provided Powershell-Script to install the Plugin:
- Download the
.zip
file applicable for your platform from the releases: - Extract it
- Execute the install-script using the following command:
powershell.exe -ExecutionPolicy Bypass .\install_plugin.ps1
- If you don't want to install the files in the plugin-directory directly, you can use the other install-script. This will let you install the files in any folder and will just create a SYMLINK in the plugin folder.
powershell.exe -ExecutionPolicy Bypass .\install_plugin_link.ps1
.
- Open PowerToys Run with
alt + space
- Type
tdh
- All available commands will be listed
- Open PowerToys Run with
alt + space
- Type
tdh bl
(local branches) ortdh br
(remote branches) - Type the name of a branch
- All branches with matching names will be listed below
- Use ⬆️ and ⬇️ keys to select a result
- Select the desired operation from the context-menu buttons
- Press
Enter
to open the branch on Jenkins - Press
Ctrl+Enter
to open the branch on Github - Press
Shift+Enter
to trigger the download of the build-artifacts for that tool
- Press
- Open PowerToys Run with
alt + space
- Type
tdh t
- Type the name of a tool
- All tools with matching short-names will be listed below
- Use ⬆️ and ⬇️ keys to select a result
- Select the desired operation from the context-menu buttons
- Press
Enter
to start the tool locally - Press
Ctrl+Enter
to open the locally started tool in the browser - Press
Shift+Enter
to open the tool on the remote-server in the browser
- Press
Execute tdh reload
to reload the tool configuration from the configured project file.
Open settings:
- Open PowerToys Settings
- Select PowerToys Run
- Scroll down to Plugins
- Expand
Tool Dev Helpers
- Git Repository URL:
URL of the GIT repository to use for the branch-helpers (remote branches) - Local source folder:
Path to a locally cloned source folder (for local branches) - Jenkins Multibranch-Pipeline URL:
URL to the base Jenkins-Multibranch-Pipeline to open the branches for - Tool folder:
Folder where the tools get downloaded to - Download Script:
Powershell-Script to download the tools with (accepts the branch-name as parameter) - Tool config file:
Configuration of all tools available for the Tool-Helpers. If the file doesn't exist yet, a sample project will be created at that location that can be adjusted. - Powershell Version
The version of Powershell to use when executing scripts (e.g. to download tools).
Available options are:- Legacy (powershell)
- Powershell 7 (pwsh)
In the tool config file you can configure all tools you want to work with.
Tip
To start of you can set the Tool config file
setting to a non-existing file. This will create a sample project which you can then adapt.
For every tool you have the following settings available:
shortName
A short abbreviation for the tool to quickly select it from the listname
The name of the tool (will be displayed in the list and in the shell window title)useHttps
True if the tool uses secure HTTPS (false or empty for HTTP) (optional)removeServerUrl
URL of the server where the tool is also deployed (optional)port
Port of the tool (optional)exePath
Relative path to the file that starts up the app (e.g. an executable)additionalPages
List of additional pages that will be opened alongside the tool itself (optional). This can be used to e.g. open a separate subpage for the API or an admin-panel. You can use one or more placeholders for various values:#BASE#
: Will be replaced with the fully formed tool URL (e.g.https://production.local:8080/
) as a placeholder, which will be replaced with the URL of the tool.#BASE_HOST#
: Will be replaced with the hostname of the tool (depending on if opened locally or remotely)#BASE_PORT#
: Will be replaced with the configured tool port
{
"toolConfigs": [
{
"shortName": "ta",
"name": "Test app",
"useHttps": true,
"remoteServerUrl": "production.local",
"port": 8080,
"exePath": "testApp/start.exe",
"additionalPages": ["#BASE#api", "#BASE_HOST#:#BASE_PORT#/test"]
}
]
}
The tool-config file changed structure after v0.0.6. If you're using an old config-file, you can migrate it to the new format using the migration script
migrate-json.ps1 old_config.json migrated_config.json