Skip to content

Instantly share code, notes, and snippets.

@schindld
schindld / .myposhtheme.omp.json
Last active October 20, 2023 17:09
Customized theme for oh-my-posh
{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"console_title_template": "{{if .Root}} \u26a1 {{end}}{{.UserName}} \u2794 📁{{.Folder}}",
"final_space": true,
"patch_pwsh_bleed": true,
"version": 2,
"blocks": [
{
"type": "prompt",
"alignment": "left",
@schindld
schindld / profile.ps1
Last active December 4, 2023 20:27
Powershell profile (init script)
# A simple implementation of refreshenv
function Update-SessionEnvironment {
# Call a powershell process to act as a wrapper to capture the output:
& ([Diagnostics.Process]::GetCurrentProcess().ProcessName) -NoP -c (
# String wrapper to help make the code more readable through comma-separation:
[String]::Join(
' ', (
# Start a process that escapes the active environment:
'Start-Process', [Diagnostics.Process]::GetCurrentProcess().ProcessName,
'-UseNewEnvironment -NoNewWindow -Wait -Args ''-c'',',