mirror of
https://github.com/Theaninova/TheaninovOS.git
synced 2025-12-13 03:56:24 +00:00
feat: integrate system config
This commit is contained in:
32
home/programs/affinity-photo.nix
Normal file
32
home/programs/affinity-photo.nix
Normal file
@@ -0,0 +1,32 @@
|
||||
{
|
||||
stdenv,
|
||||
fetchurl,
|
||||
pkgs,
|
||||
p7zip,
|
||||
wineWowPackages,
|
||||
winetricks,
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
name = "affinity-photo";
|
||||
version = "1.10.6";
|
||||
|
||||
src = ./affinity-photo-${version}.exe;
|
||||
dontUnpack = true;
|
||||
|
||||
buildInputs = [wineWowPackages.stable winetricks];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/share/$name
|
||||
cd $out/share/$name
|
||||
${p7zip}/bin/7z x $src
|
||||
|
||||
mkdir -p $out/bin
|
||||
cd $out/bin
|
||||
echo "#!${stdenv.shell}" >> $name
|
||||
echo "export WINEARCH=win64" >> $name
|
||||
echo "export WINEPREFIX=~/.config/$name" >> $name
|
||||
echo "${winetricks}/bin/winetricks -q corefonts dotnet472" >> $name
|
||||
echo "${wineWowPackages.stable}/bin/wine $out/share/$name/App.exe" >> $name
|
||||
chmod +x $name
|
||||
'';
|
||||
}
|
||||
Reference in New Issue
Block a user