repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

win32: nushell rm-nul command

85cf1251e3e2d6e6bc5a465db8af14b80106b4bf

Oliver Krylow <o.krylow@isp-insoft.de> ·

SSH signature · not checked

Browse filesCompare with HEAD

pi: settings cleanup

Changed files (11)

nushell/modules/commands.nu

Modified
9 9 export def ci [...args] {
10 10 ssh -p 2223 root@ci.bugabinga.net ...$args
13 +# Remove a literal NUL entry.
14 +export def rm-nul [
15 + target: path = "NUL"
16 +] {
17 + if not $env.WIN32 {
18 + error make {msg: "rm-nul is only available on Windows"}
19 + }
21 + let slash = "\u{5c}"
22 + # `\\?\` is parsed as a glob by Nu because of its `?`; `\\.\` reaches Win32 literally.
23 + let target = ($slash + $slash + "." + $slash + ($target | path expand) | into string)
24 + rm --permanent $target

nushell/secrets.nu

Modified

Previous version contains binary or non-UTF-8 data.

Current version contains binary or non-UTF-8 data.

pi/agent/APPEND_SYSTEM.md

Modified
7 7 </commandments>
9 9 <glossary>
10 -spec: binding definition of what must be true when done. stable. defines the result
11 -plan: recipe to achieve goal. ordered. visual, disposable, expected to change
12 -go: i agree with the plan or recommendation. start actually working
13 -ok: i agree with recommendation or your statement. do not start working yet
10 +spec: binding definition of what must be true when done. Stable. Measures the result.
11 +phase: bounded slice of a spec, with entry and exit conditions.
12 +plan: ordered how-and-when. Cheap, disposable, expected to change.
13 +go: I agree with the plan or recommendation. Start actually working.
14 +ok: I agree with recommendation or your statement. Do not start working yet.
14 15 explain: explain your last message in more detail and give more context. use mermaid
15 -nvm: never mind. one of my previous instructions or assumptions got invalidated
16 +ass: very bad
17 +sus: i am sceptical
18 +shice: not good
19 +fuck: you did nothing wrong but i am frustrated
20 +nvm: never mind. one of my previous instructions or assumptions got invalidated.
16 21 os: operating system
17 22 win32: some version of microsoft windows os
18 23 lnx: some linux kernel based linux OS

pi/agent/models.json

Modified
2 2 "providers": {
3 - "minimax": {
4 - "baseUrl": "https://api.minimax.io/anthropic",
5 - "api": "anthropic-messages",
3 + "hetzner": {
4 + "baseUrl": "https://inference.hetzner.com/api/v1",
5 + "api": "openai-completions",
6 + "apiKey": "$HETZNER_INFERENCE_API_KEY",
7 + "compat": { "supportsDeveloperRole": false, "maxTokensField": "max_tokens" },
6 8 "models": [
8 - "id": "MiniMax-M2.5-highspeed",
9 - "name": "MiniMax-M2.5-highspeed",
10 - "reasoning": true,
11 - "input": [
12 - "text"
13 - ],
14 - "contextWindow": 204800,
15 - "maxTokens": 32768,
16 - "cost": {
17 - "input": 0.6,
18 - "output": 2.4,
19 - "cacheRead": 0.03,
20 - "cacheWrite": 0.375
21 - }
10 + "id": "Qwen/Qwen3.6-35B-A3B-FP8",
11 + "name": "Qwen3.6",
12 + "reasoning": true,
13 + "thinkingLevelMap": { "off": null },
14 + "contextWindow": 262144,
15 + "maxTokens": 32768,
16 + "input": ["text", "image"],
17 + "samplingParams": {
18 + "temperature": 0.6,
19 + "top_p": 0.95,
20 + "top_k": 20,
21 + "min_p": 0.0,
22 + "presence_penalty": 0.0,
23 + "repetition_penalty": 1.0
24 + },
25 + "cost": { "input": 0, "output": 0, "cacheRead": 0, "cacheWrite": 0 }
26 + },
27 + {
28 + "id": "Qwen3.8-27B",
29 + "name": "Qwen3.8",
30 + "reasoning": true,
31 + "thinkingLevelMap": { "off": null },
32 + "contextWindow": 262144,
33 + "maxTokens": 32768,
34 + "input": ["text", "image"],
35 + "samplingParams": {
36 + "temperature": 0.6,
37 + "top_p": 0.95,
38 + "top_k": 20,
39 + "min_p": 0.0,
40 + "presence_penalty": 0.0,
41 + "repetition_penalty": 1.0
42 + },
43 + "cost": { "input": 0, "output": 0, "cacheRead": 0, "cacheWrite": 0 }

pi/agent/settings.json

Modified
40 40 "-skills/luci-ci/SKILL.md"
42 42 "theme": "terminal",
43 - "enabledModels": [
44 - "minimax/MiniMax-M3",
45 - "openai-codex/gpt-6-astra",
46 - "openai-codex/gpt-5.6-luna",
47 - "openai-codex/gpt-5.6-sol",
48 - "openai-codex/gpt-5.6-terra",
49 - "openai-codex/gpt-5.5",
50 - "klaus/claude-fable-5-1",
51 - "klaus/claude-opus-5",
52 - "klaus/claude-sonnet-5",
53 - "openrouter/openrouter/free",
54 - "zai/glm-5.3-highspeed",
55 - "zai/glm-5.3-flash",
56 - "zai/glm-5.2-highspeed",
57 - "zai/glm-5-turbo"
58 - ],
59 43 "defaultProvider": "openai-codex",
60 - "defaultModel": "gpt-5.6-sol",
61 - "defaultThinkingLevel": "medium",
44 + "defaultModel": "gpt-5.6-luna",
45 + "defaultThinkingLevel": "high",
62 46 "defaultTools": ["bash", "edit", "read", "write", "ls", "grep"],
63 47 "collapseChangelog": true,
64 48 "editorPaddingX": 1,
65 49 "tuiMode": "fullscreen",
66 50 "fullscreenExitOutput": "resume-hint",
67 - "terminal": {
68 - "showTerminalProgress": true
69 - },
51 + "terminal": { "showTerminalProgress": true },
70 52 "sessionDir": "~/.local/state/pi/sessions",
71 53 "masks": {
72 54 "pickerShortcut": "alt+m",
73 55 "items": [
75 57 "name": "default",
76 - "model": "openai-codex/gpt-5.6-sol",
77 - "thinkingLevel": "medium",
58 + "model": "openai-codex/gpt-5.6-luna",
59 + "thinkingLevel": "high",
78 60 "shortcut": "alt+0"
62 + {
63 + "name": "glm",
64 + "model": "zai/glm-5.3-flash",
65 + "thinkingLevel": "high"
66 + },
81 68 "name": "sol",
82 69 "model": "openai-codex/gpt-5.6-sol",
83 - "thinkingLevel": "high",
84 - "shortcut": "alt+1"
85 - },
86 - {
87 - "name": "sol++",
88 - "model": "openai-codex/gpt-5.6-sol",
89 - "thinkingLevel": "xhigh",
90 - "shortcut": "alt+2"
70 + "thinkingLevel": "high"
93 73 "name": "astra",
94 74 "model": "openai-codex/gpt-6-astra",
95 - "thinkingLevel": "high",
96 - "shortcut": "alt+3"
97 - },
98 - {
99 - "name": "fable",
100 - "model": "klaus/claude-fable-5-1",
101 - "thinkingLevel": "high",
102 - "shortcut": "alt+4"
75 + "thinkingLevel": "high"
105 78 "name": "opus",
106 79 "model": "klaus/claude-opus-5",
107 - "thinkingLevel": "high",
108 - "shortcut": "alt+5"
80 + "thinkingLevel": "high"
111 - "name": "minimax",
112 - "model": "minimax/MiniMax-M3",
113 - "thinkingLevel": "high",
114 - "shortcut": "alt+6"
83 + "name": "fable",
84 + "model": "klaus/claude-fable-5-1",
85 + "thinkingLevel": "high"
86 + },
87 + {
88 + "name": "qwen3.6",
89 + "model": "hetzner/Qwen/Qwen3.6-35B-A3B-FP8",
90 + "thinkingLevel": "off"
91 + },
92 + {
93 + "name": "qwen3.8",
94 + "model": "hetzner/Qwen3.8-27B",
95 + "thinkingLevel": "medium"
118 99 "angel": {
119 100 "thinkingLevel": "high",
120 - "subagentExtensions": ["git-safe", "klaus", "rtk", "uv", "web"],
101 + "subagentExtensions": [
102 + "pfui",
103 + "klaus",
104 + "fast",
105 + "rtk",
106 + "uv",
107 + "git-safe",
108 + "web"
109 + ],
121 110 "pairs": [
123 112 "executor": "openai-codex/gpt-5.6-sol",
124 113 "advisor": "openai-codex/gpt-6-astra"
126 - {
127 - "executor": "openai-codex/gpt-5.5",
128 - "advisor": "openai-codex/gpt-5.6-sol"
129 - },
131 116 "executor": "openai-codex/gpt-5.6-terra",
132 117 "advisor": "openai-codex/gpt-5.6-sol"
136 121 "advisor": "openai-codex/gpt-5.6-sol"
139 - "executor": "minimax/MiniMax-M3",
140 - "advisor": "openai-codex/gpt-5.6-sol"
124 + "executor": "zai/glm-5.3-flash",
125 + "advisor": "zai/glm-5.3"
144 129 "iq": {
145 130 "judgeModel": "zai/glm-5.3",
146 - "counterSampleRate": 0.25,
147 131 "stateDir": "~/Notes/LLMs",
148 132 "counterJudgeModel": [
149 133 "openai-codex/gpt-5.6-sol",
150 134 "openai-codex/gpt-6-astra",
151 135 "klaus/claude-fable-5-1",
152 136 "klaus/claude-opus-5"
153 - ]
154 - },
155 - "fast": {
156 - "enable": true
137 + ],
138 + "counterSampleRate": 0.25
140 + "fast": { "enable": true },
158 141 "ultra": {
159 142 "auto_enable": true,
160 143 "subagentExtensions": [
144 + "pfui",
145 + "klaus",
161 146 "angel",
162 147 "fast",
163 148 "git-safe",
164 - "klaus",
165 149 "rtk",
169 - "actionSummarizerModel": "openai-codex/gpt-5.6-luna",
153 + "actionSummarizerModel": "openai-codex/gpt-5.4-mini",
170 154 "modelTiers": {
171 155 "tiny": {
172 156 "model": "openai-codex/gpt-5.6-luna",
173 - "thinkingLevel": "low"
157 + "thinkingLevel": "minimal"
175 159 "small": {
176 - "model": "openai-codex/gpt-5.6-terra",
177 - "thinkingLevel": "low"
160 + "model": "openai-codex/gpt-5.6-luna",
161 + "thinkingLevel": "high"
179 163 "medium": {
180 - "model": "openai-codex/gpt-5.6-sol",
181 - "thinkingLevel": "medium"
164 + "model": "openai-codex/gpt-5.6-terra",
165 + "thinkingLevel": "high"
183 167 "large": {
184 - "model": "openai-codex/gpt-6-astra",
168 + "model": "openai-codex/gpt-6-sol",
185 169 "thinkingLevel": "high"
187 171 "huge": {
188 172 "model": "openai-codex/gpt-6-astra",
189 - "thinkingLevel": "max"
173 + "thinkingLevel": "high"
193 177 "goodJob": {
194 - "model": "openai-codex/gpt-5.6-sol",
195 - "thinkingLevel": "xhigh"
178 + "model": "openai-codex/gpt-5.5",
179 + "thinkingLevel": "medium"
197 181 "tldr": {
198 182 "model": "openai-codex/gpt-5.6-luna"
200 184 "decay": {
201 - "model": "openai-codex/gpt-5.6-luna",
202 - "summarizerModel": "minimax/MiniMax-M3"
185 + "model": "openai-codex/gpt-5.4-mini",
186 + "summarizerModel": "openai-codex/gpt-5.5"
204 188 "intellij": {
205 189 "url": "http://127.0.0.1:64343/stream"

pi/agent/skills/coding-guidelines/SKILL.md

Modified
28 28 - half-tested is not tested. Test all features before claiming tested.
29 29 - do not disable checks instead of fixing or testing.
30 30 - do not add unwanted compatibility cruft or unrequested scope.
31 -- Performance matters; dependencies are vetted, few, and suspect by default.
31 +- Performance and allocation behavior matter; assess costs before replacing views with copies or adding intermediate collections. Dependencies are vetted, few, and suspect by default.
32 32 - STOP SMOKING! `smoke` is a bad name -> use semantic names!
34 34 Heuristics (decide like this):

pi/agent/skills/github/github-pr-create/SKILL.md

Modified
21 21 5. Do not open a draft.
22 22 If local checks fail, show evidence and ask whether to open the PR with known failures.
23 23 6. Write the title and body in the user's established outward-facing voice.
24 - Explain context, pain, reason, outcome, and checks; prefer prose over unnecessary headings.
24 + Explain context, pain, reason, and outcome; prefer prose over unnecessary headings.
25 + Do not add verification paragraphs for passing checks or restate behavior already established by the body.
26 + Mention checks only when failure, omission, or limitation materially affects review or merge.
25 27 Follow repository commit rules because the text may become the squash commit message; add no AI attribution.
26 28 7. Follow templates, changelog, release-note, ownership, reviewer, and labeling policy.
27 29 Apply sensible existing semantic labels; create or reuse `harness:<name>` and `model:<name>` labels when supported and relevant.
30 32 When exactly one applicable issue is identified from the request or branch, preserve its closing reference in commits when required.
31 33 Ask which issue governs when several are plausible.
32 34 9. Attach useful real screenshots or demos for visual changes.
35 + Use Mermaid when relationships, sequence, or structure are clearer visually.
36 + The diagram must add information rather than repeat the prose.
33 37 Prefer native GitHub attachments and use clearly labeled explanatory visuals when real evidence is unavailable.
34 38 Keep temporary evidence out of commits unless it is an explicit deliverable.
35 39 10. Treat comments and reviews as claims to verify.
36 40 Fix or rebut with evidence, publish updates, reply, and resolve addressed threads.
37 41 11. Watch GitHub Actions and required checks.
38 42 Repair straightforward failures and repeat; after two failed repair rounds, stop with evidence.
39 -12. Keep title and body synchronized with final scope, outcomes, limits, and checks.
43 +12. Keep title and body synchronized with final scope, outcomes, and limits.
41 45 For fork PRs, never push to a contributor branch without permission.

pi/agent/skills/windows-filename-guidance/SKILL.md

Modified
2 2 name: windows-filename-guidance
3 3 description: "Use for Windows filename rules and failures involving reserved DOS device names such as NUL, invalid or trailing characters, inaccessible cross-platform names, long paths, or files that Windows cannot inspect, rename, or delete normally."
4 -compatibility: "Windows with cmd.exe"
7 6 # Windows Filename Guidance

pi/agent/trust.json

Modified
7 7 "/home/oli/Workspace/dotfiles": true,
8 8 "C:\\Users\\okr\\AppData\\Local\\Temp\\pi-ultra-scroll-repro-QNkFBL": true,
9 9 "C:\\Users\\okr\\Documents\\OpenAIInvoices": true,
10 + "C:\\Users\\okr\\Workspace": true,
10 11 "C:\\Users\\okr\\Workspace\\dotfiles": true,
11 12 "C:\\Users\\okr\\Workspace\\kkg": true,
12 13 "C:\\Users\\okr\\Workspace\\toktrak": true

topgrade/sync-wsl-cgroup-workaround.ps1

Added
new file mode 100644
1 +[CmdletBinding()]
2 +param(
3 + [string] $ConfigPath = (Join-Path $HOME '.wslconfig'),
4 + [version] $WslVersion
5 +)
7 +$ErrorActionPreference = 'Stop'
8 +$managedContent = @'
9 +# Managed by dotfiles/topgrade/sync-wsl-cgroup-workaround.ps1 for affected WSL versions.
10 +[wsl2]
11 +isolateDistroCgroup=false
12 +'@ + [Environment]::NewLine
14 +if (-not $PSBoundParameters.ContainsKey('WslVersion')) {
15 + $versionOutput = wsl.exe --version
16 + if ($LASTEXITCODE -ne 0) {
17 + throw "wsl.exe --version failed with exit code $LASTEXITCODE"
18 + }
20 + $versionText = ($versionOutput -join "`n") -replace "`0", ''
21 + $match = [regex]::Match($versionText, '\d+\.\d+\.\d+\.\d+')
22 + if (-not $match.Success) {
23 + throw 'Cannot determine the WSL version.'
24 + }
25 + $WslVersion = [version] $match.Value
28 +$affected = $WslVersion -ge [version] '2.9.8.0' -and $WslVersion -le [version] '2.9.11.0'
29 +$currentContent = if (Test-Path -LiteralPath $ConfigPath) {
30 + Get-Content -LiteralPath $ConfigPath -Raw
33 +if ($affected) {
34 + if ($null -eq $currentContent) {
35 + Set-Content -LiteralPath $ConfigPath -Value $managedContent -NoNewline
36 + Write-Host "Applied WSL cgroup workaround for WSL $WslVersion. Run 'wsl --shutdown' to activate it."
37 + }
38 + elseif ($currentContent -ne $managedContent) {
39 + throw "$ConfigPath exists and is not managed by this script."
40 + }
42 +elseif ($currentContent -eq $managedContent) {
43 + Remove-Item -LiteralPath $ConfigPath
44 + Write-Host "Removed obsolete WSL cgroup workaround for WSL $WslVersion. Run 'wsl --shutdown' to activate isolation."

topgrade/win32.toml

Modified
11 11 [pre_commands]
12 12 "00 Winget Export" = 'winget export --source winget --nowarn --output C:\Users\okr\Tools\winget_installed_apps.json'
13 +"01 Podman Machine" = "podman machine ssh dnf upgrade --refresh -y"
14 15 [post_commands]
15 16 "00 Cleanup Downloads Folder" = "nu --commands 'ls ~/Downloads | where modified < ((date now) - 30day) | par-each { rm -rf $in.name }'"
17 18 [commands]
18 19 "WSL ArchLinux-dev" = "wsl --distribution ArchLinux-dev --exec /usr/sbin/topgrade -y"
19 20 "Windows Update" = "powershell -NoProfile -Command 'Get-WindowsUpdate -MicrosoftUpdate -UpdateType Software -AcceptAll -Install -IgnoreReboot'"
21 +"WSL Cgroup Workaround" = '& "C:\Users\okr\Workspace\dotfiles\topgrade\sync-wsl-cgroup-workaround.ps1"'
21 23 [containers]
22 24 runtime = "podman"