r/PowerShell • u/Arch1Frost • 16d ago
Question why is it allways starting on system32?! it should start on the desktop...
here is the config:
{
"$help": "https://aka.ms/terminal-documentation",
"$schema": "https://aka.ms/terminal-profiles-schema",
"actions": [],
"alwaysShowNotificationIcon": true,
"centerOnLaunch": true,
"copyFormatting": "none",
"copyOnSelect": false,
"defaultProfile": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
"keybindings":
[
{
"id": "Terminal.CopyToClipboard",
"keys": "ctrl+c"
},
{
"id": "Terminal.FindText",
"keys": "ctrl+shift+f"
},
{
"id": "Terminal.PasteFromClipboard",
"keys": "ctrl+v"
},
{
"id": "Terminal.CloseWindow",
"keys": "ctrl+f"
},
{
"id": "Terminal.DuplicatePaneAuto",
"keys": "alt+shift+d"
},
{
"id": "Terminal.OpenSettingsUI",
"keys": "ctrl+m"
}
],
"launchMode": "focus",
"newTabMenu":
[
{
"type": "remainingProfiles"
}
],
"newTabPosition": "afterLastTab",
"profiles":
{
"defaults":
{
"adjustIndistinguishableColors": "indexed",
"antialiasingMode": "cleartype",
"colorScheme": "One Half Dark",
"experimental.retroTerminalEffect": false,
"font":
{
"face": "JetBrainsMono Nerd Font"
},
"opacity": 0,
"padding": "15",
"startingDirectory": "C:\\Users\\maxsu\\Desktop",
"useAcrylic": false
},
"list":
[
{
"backgroundImage": null,
"backgroundImageOpacity": 0.07,
"colorScheme": "Ottosson",
"commandline": "%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe",
"font":
{
"face": "JetBrainsMono Nerd Font"
},
"guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
"hidden": false,
"name": "Windows PowerShell",
"opacity": 0,
"scrollbarState": "hidden",
"startingDirectory": "C:\\Users\\maxsu\\Desktop",
"useAcrylic": true
},
{
"commandline": "%SystemRoot%\\System32\\cmd.exe",
"guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
"hidden": false,
"name": "\u041a\u043e\u043c\u0430\u043d\u0434\u043d\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430",
"opacity": 100,
"startingDirectory": "C:\\Users\\maxsu\\Desktop",
"useAcrylic": false
},
{
"guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}",
"hidden": false,
"name": "Azure Cloud Shell",
"source": "Windows.Terminal.Azure"
},
{
"guid": "{6cff44b8-d193-55cd-b6c4-1c4f7101be95}",
"hidden": false,
"name": "Developer Command Prompt for VS 2022",
"source": "Windows.Terminal.VisualStudio"
},
{
"guid": "{5e05125c-0fdd-503e-8586-c85e104b19de}",
"hidden": false,
"name": "Developer PowerShell for VS 2022",
"source": "Windows.Terminal.VisualStudio"
}
]
},
"rendering.graphicsAPI": "direct3d11",
"schemes":
[
{
"background": "#18181B",
"black": "#18181B",
"blue": "#E5E7EB",
"brightBlack": "#4B565C",
"brightBlue": "#E5E7EB",
"brightCyan": "#E5E7EB",
"brightGreen": "#E5E7EB",
"brightPurple": "#E5E7EB",
"brightRed": "#E5E7EB",
"brightWhite": "#E5E7EB",
"brightYellow": "#E5E7EB",
"cursorColor": "#E5E7EB",
"cyan": "#E5E7EB",
"foreground": "#E5E7EB",
"green": "#E5E7EB",
"name": "Monochrome",
"purple": "#E5E7EB",
"red": "#E5E7EB",
"selectionBackground": "#18181B",
"white": "#E5E7EB",
"yellow": "#E5E7EB"
}
],
"showTabsInTitlebar": true,
"tabSwitcherMode": "mru",
"tabWidthMode": "compact",
"theme": "system",
"themes":
[
{
"name": "Monochrome",
"tab":
{
"background": "#18181BFF",
"iconStyle": "default",
"showCloseButton": "always",
"unfocusedBackground": null
},
"tabRow":
{
"background": "#E6E9EFFF",
"unfocusedBackground": "#DCE0E8FF"
},
"window":
{
"applicationTheme": "light",
"experimental.rainbowFrame": false,
"frame": null,
"unfocusedFrame": null,
"useMica": false
}
}
],
"useAcrylicInTabRow": true
}
6
u/BlackV 16d ago edited 16d ago
stop running elevated by default
configure a profile with a start folder (although desktop seems just as lunatic a location as system32)
configure windows terminal (if you're using it) with a start folder
p.s. formatting
it'll format it properly OR
Inline code block using backticks
`Single code line`inside normal textSee here for more detail
Thanks
8
u/sirchandwich 16d ago
What is this? If you don’t want Admin to open as System32 just change your starting directory in the settings
5
u/LBik 16d ago
I think you have enough vodka for this evening.
1
u/Lonely_Noyaaa 15d ago
Your config already has startingDirectory set to Desktop for both the default profile and the PowerShell entry, so the setting is not the problem. The likely culprit is elevation, because an elevated session often inherits System32 regardless of what Windows Terminal asks for.
0
u/MonkeyNin 14d ago
If you use google-ai on your thread it gives pretty good answers. The prompt I used was
0
u/gowinder 16d ago
It's not PowerShell picking that folder — whoever launched the shell hands it down, and your profile with the
{61c54bbd-c2c6-5271-96e7-009a87ff44bf}GUID has nostartingDirectory, so it keeps the inherited one. In Windows Terminal, setstartingDirectoryto%USERPROFILE%; it expands%VAR%but not~. A named profile block overridesdefaults, so if both exist, set both.