mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-11-13 12:13:36 +01:00
* feat(nixpak): sandbox six desktop apps * chore(nixpak): trim OBS plugin set * fix(nixpak): enable OBS on aarch64 * fix(nixpak): let imv read the full home directory * fix(home): drop redundant freerdp package * fix(nixpak): grant OBS access to V4L2 camera devices * fix(nixpak): expose V4L2 sysfs to OBS * fix(nixpak): expose NVIDIA encode library to OBS * docs(nixpak): record OBS interactive validation * docs(nixpak): record OBS RTMP validation * fix(nixpak): run MuseScore via XWayland and PulseAudio * docs(nixpak): explain app sandboxing rationale * fix(nixpak): route MuseScore ALSA through PipeWire
65 lines
1.4 KiB
Nix
65 lines
1.4 KiB
Nix
{
|
|
lib,
|
|
musescore,
|
|
mkNixPak,
|
|
buildEnv,
|
|
makeDesktopItem,
|
|
runCommandLocal,
|
|
...
|
|
}:
|
|
let
|
|
appId = "org.musescore.MuseScore";
|
|
wrapped = mkNixPak {
|
|
config = {
|
|
imports = [ ./modules/musescore-policy.nix ];
|
|
app = {
|
|
package = musescore;
|
|
binPath = "bin/mscore";
|
|
};
|
|
flatpak = { inherit appId; };
|
|
};
|
|
};
|
|
exe = lib.getExe wrapped.config.script;
|
|
assets = runCommandLocal "musescore-desktop-assets" { } ''
|
|
mkdir -p $out/share
|
|
ln -s ${musescore}/share/icons $out/share/icons
|
|
'';
|
|
in
|
|
buildEnv {
|
|
inherit (wrapped.config.script) name passthru;
|
|
meta = wrapped.config.script.meta // {
|
|
mainProgram = "mscore";
|
|
};
|
|
paths = [
|
|
wrapped.config.script
|
|
assets
|
|
(makeDesktopItem {
|
|
name = appId;
|
|
desktopName = "MuseScore Studio";
|
|
genericName = "Music Notation";
|
|
comment = "Create, play and print sheet music";
|
|
exec = "${exe} %U";
|
|
icon = "mscore";
|
|
terminal = false;
|
|
startupNotify = true;
|
|
startupWMClass = "MuseScore4";
|
|
categories = [
|
|
"AudioVideo"
|
|
"Audio"
|
|
"Graphics"
|
|
"Midi"
|
|
"Music"
|
|
];
|
|
mimeTypes = [
|
|
"application/x-musescore"
|
|
"application/x-musescore+xml"
|
|
"application/vnd.recordare.musicxml"
|
|
"application/vnd.recordare.musicxml+xml"
|
|
"audio/midi"
|
|
"x-scheme-handler/musescore"
|
|
];
|
|
extraConfig.X-Flatpak = appId;
|
|
})
|
|
];
|
|
}
|