Hide VSCodium title bar via workbench.html CSS injection

Override vscodium with a postFixup step that appends a style tag to
workbench.html hiding the titlebar part, so the window sits flush
against GNOME's edge without native or custom decorations.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
ediblerope 2026-04-16 19:40:31 +01:00
parent 8b9d3d86cc
commit 43a8cb976c

View file

@ -21,7 +21,15 @@
adwsteamgtk
proton-vpn
onlyoffice-desktopeditors
vscodium
(vscodium.overrideAttrs (old: {
postFixup = (old.postFixup or "") + ''
workbenchHtml="$out/lib/vscode/resources/app/out/vs/code/electron-browser/workbench/workbench.html"
if [ -f "$workbenchHtml" ]; then
substituteInPlace "$workbenchHtml" \
--replace-fail '</head>' '<style>.monaco-workbench .part.titlebar { display: none !important; }</style></head>'
fi
'';
}))
];
programs.nix-ld.enable = true;