Skip to content

Instantly share code, notes, and snippets.

@code2exe
Last active February 28, 2020 16:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save code2exe/5b53b61ec4badf89707f82d4be426205 to your computer and use it in GitHub Desktop.
Save code2exe/5b53b61ec4badf89707f82d4be426205 to your computer and use it in GitHub Desktop.
My minimal Windows Terminal profiles.json file
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"globals": {
"alwaysShowTabs": true,
"initialCols": 120,
"initialRows": 30,
"defaultProfile": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
// Add any keybinding overrides to this array.
// To unbind a default keybinding, set the command to "unbound"
"keybindings": [
{
"command": "closeTab",
"keys": [
"ctrl+w"
]
},
{
"command": "newTab",
"keys": [
"ctrl+t"
]
},
{
"command": "nextTab",
"keys": [
"ctrl+tab"
]
},
{
"command": "prevTab",
"keys": [
"ctrl+shift+tab"
]
},
{
"command": "scrollDown",
"keys": [
"ctrl+shift+down"
]
},
{
"command": "scrollDownPage",
"keys": [
"ctrl+shift+pgdn"
]
},
{
"command": "scrollUp",
"keys": [
"ctrl+shift+up"
]
},
{
"command": "scrollUpPage",
"keys": [
"ctrl+shift+pgup"
]
},
{
"command": "switchToTab0",
"keys": [
"alt+1"
]
},
{
"command": "switchToTab1",
"keys": [
"alt+2"
]
},
{
"command": "switchToTab2",
"keys": [
"alt+3"
]
},
{
"command": "switchToTab3",
"keys": [
"alt+4"
]
},
{
"command": "switchToTab4",
"keys": [
"alt+5"
]
},
{
"command": "switchToTab5",
"keys": [
"alt+6"
]
},
{
"command": "switchToTab6",
"keys": [
"alt+7"
]
},
{
"command": "switchToTab7",
"keys": [
"alt+8"
]
},
{
"command": "switchToTab8",
"keys": [
"alt+9"
]
},
{
"command": "splitHorizontal",
"keys": [
"ctrl+-"
]
},
{
"command": "splitVertical",
"keys": [
"ctrl+\\"
]
}
]
},
"profiles":
[
{
// Make changes here to the cmd.exe profile
"guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
"name": "cmd",
"commandline": "yori.exe",
"cursorShape": "vintage",
"cursorColor": "#00FF00",
"fontFace": "Delugia Nerd Font",
"fontColor": "#00FF00",
"acrylicOpacity": 0.2,
"useAcrylic": false,
"backgroundImage": "C:/Users/Henry/Pictures/402208.png",
"backgroundImageOpacity" : 0.5,
"startingDirectory": "C:/Users/Henry/Desktop",
"hidden": false,
"padding" : "0, 0, 0, 0",
"snapOnInput" : true,
"historySize": 9001
},
{
"guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
"hidden": false,
"name": "PowerShell Core",
"commandline": "pwsh.exe",
"icon" : "ms-appx:///ProfileIcons/{574e775e-4f2a-5b96-ac1e-a2962a402336}.png",
"useArylic": true,
"acrylicOpacity": 0.5,
"backgroundImage": "C:/Users/Henry/Pictures/402208.png",
"backgroundImageOpacity" : 0.2,
"cursorShape": "vintage",
"cursorColor": "#00FF00",
"fontFace": "Cascadia Code PL",
"startingDirectory": "C:/Users/Henry/Desktop",
"padding" : "0, 0, 0, 0",
"snapOnInput" : true,
"historySize": 9001,
"tabTitle": "PowerShell Core"
},
{
// Make changes here to the powershell.exe profile
"guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
"name": "Windows PowerShell",
"commandline": "powershell.exe",
"hidden": false,
"cursorShape": "underscore",
"fontFace": "Cascadia Code PL",
"cursorColor": "#00FF00",
"backgroundImage": "C:/Users/Henry/Pictures/402208.png",
"backgroundImageOpacity" : 0.2,
"acrylicOpacity": 0.5,
"useAcrylic": true
},
{
"guid": "{c6eaf9f4-32a7-5fdc-b5cf-066e8a4b1e40}",
"hidden": false,
"name": "Ubuntu-18.04",
"source": "Windows.Terminal.Wsl",
"cursorColor": "#00FF00",
"acrylicOpacity": 0.8,
"fontFace": "Delugia Nerd Font",
"useAcrylic": true
},
{
"guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}",
"hidden": false,
"name": "Azure Cloud Shell",
"source": "Windows.Terminal.Azure"
}
],
// Add custom color schemes to this array
"schemes": []
}
@code2exe
Copy link
Author

code2exe commented Feb 28, 2020

Command Line Arguments

The wt execution alias now supports command line arguments! You can now launch Terminal with new tabs and panes split just how you like, with the profiles you like, starting in the directories you like! The possibilities are endless! Here are some examples:

wt -d .

  • Opens the Terminal with the default profile in the current working directory.

wt -d . ; new-tab -d C:\ pwsh.exe

  • Opens the Terminal with two tabs. The first is running the default profile starting in the current working directory. The second is using the default profile with pwsh.exe as the "commandline" (instead of the default profile’s "commandline") starting in the C:\ directory.

wt -p "Windows PowerShell" -d . ; split-pane -V wsl.exe

  • Opens the Terminal with two panes, split vertically. The top pane is running the profile with the name “Windows Terminal” and the bottom pane is running the default profile using wsl.exe as the "commandline" (instead of the default profile’s "commandline").

For a full documentation, Visit:
https://github.com/microsoft/terminal/blob/master/doc/user-docs/UsingCommandlineArguments.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment