some stuff

This commit is contained in:
xunuwu 2024-06-07 18:30:15 +02:00
parent d2fd9fda8a
commit 368fc628c2
Signed by: xun
SSH key fingerprint: SHA256:Uot/1WoAjWAeqLOHA5vYy4phhVydsH7jCPmBjaPZfgI
26 changed files with 458 additions and 97 deletions

86
flake.lock generated
View file

@ -10,11 +10,11 @@
"systems": "systems"
},
"locked": {
"lastModified": 1715290355,
"narHash": "sha256-2T7CHTqBXJJ3ZC6R/4TXTcKoXWHcvubKNj9SfomURnw=",
"lastModified": 1716561646,
"narHash": "sha256-UIGtLO89RxKt7RF2iEgPikSdU53r6v/6WYB0RW3k89I=",
"owner": "ryantm",
"repo": "agenix",
"rev": "8d37c5bdeade12b6479c85acd133063ab53187a0",
"rev": "c2fc0762bbe8feb06a2e59a364fa81b3a57671c9",
"type": "github"
},
"original": {
@ -77,11 +77,11 @@
},
"locked": {
"dir": "pkgs/firefox-addons",
"lastModified": 1716264197,
"narHash": "sha256-ryPizz6evZsfAjFjUWgxCVzBZ9m1BDVKlMomOHze8VE=",
"lastModified": 1717214600,
"narHash": "sha256-6cL574j1SSL9At2oZwGarAv9FcwphI9Pd8im+uQ5/bE=",
"owner": "rycee",
"repo": "nur-expressions",
"rev": "cccd903ebbe5837579d6746ac430beec60d96c19",
"rev": "4118c12978f50c094d2e40146d2b1524012a6dd5",
"type": "gitlab"
},
"original": {
@ -186,11 +186,11 @@
"nixpkgs-lib": "nixpkgs-lib"
},
"locked": {
"lastModified": 1715865404,
"narHash": "sha256-/GJvTdTpuDjNn84j82cU6bXztE0MSkdnTWClUCRub78=",
"lastModified": 1717285511,
"narHash": "sha256-iKzJcpdXih14qYVcZ9QC9XuZYnPc6T8YImb6dX166kw=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "8dc45382d5206bd292f9c2768b8058a8fd8311d9",
"rev": "2a55567fcf15b1b1c7ed712a2c6fadaec7412ea8",
"type": "github"
},
"original": {
@ -358,11 +358,11 @@
},
"hardware": {
"locked": {
"lastModified": 1716173274,
"narHash": "sha256-FC21Bn4m6ctajMjiUof30awPBH/7WjD0M5yqrWepZbY=",
"lastModified": 1717248095,
"narHash": "sha256-e8X2eWjAHJQT82AAN+mCI0B68cIDBJpqJ156+VRrFO0=",
"owner": "nixos",
"repo": "nixos-hardware",
"rev": "d9e0b26202fd500cf3e79f73653cce7f7d541191",
"rev": "7b49d3967613d9aacac5b340ef158d493906ba79",
"type": "github"
},
"original": {
@ -483,11 +483,11 @@
]
},
"locked": {
"lastModified": 1715930644,
"narHash": "sha256-W9pyM3/vePxrffHtzlJI6lDS3seANQ+Nqp+i58O46LI=",
"lastModified": 1717097707,
"narHash": "sha256-HC5vJ3oYsjwsCaSbkIPv80e4ebJpNvFKQTBOGlHvjLs=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "e3ad5108f54177e6520535768ddbf1e6af54b59d",
"rev": "0eb314b4f0ba337e88123e0b1e57ef58346aafd9",
"type": "github"
},
"original": {
@ -619,11 +619,11 @@
]
},
"locked": {
"lastModified": 1716170277,
"narHash": "sha256-fCAiox/TuzWGVaAz16PxrR4Jtf9lN5dwWL2W74DS0yI=",
"lastModified": 1717297675,
"narHash": "sha256-43UmlS1Ifx17y93/Vc258U7bOlAAIZbu8dsGDHOIIr0=",
"owner": "Mic92",
"repo": "nix-index-database",
"rev": "e0638db3db43b582512a7de8c0f8363a162842b9",
"rev": "972a52bee3991ae1f1899e6452e0d7c01ee566d9",
"type": "github"
},
"original": {
@ -639,11 +639,11 @@
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1716254495,
"narHash": "sha256-2cOTkGglFvwxnVpK1BiIU1ZTT7P0qGxW99UCPoDPBxI=",
"lastModified": 1717291708,
"narHash": "sha256-9oqdLMnfzywk1B2Lx6jQP6mAL6or6clVtOp+vXBsn9E=",
"owner": "nix-community",
"repo": "nix-vscode-extensions",
"rev": "deab460d7d0ec00eb7bd7b87044882c7ddfbf293",
"rev": "4b46d344b7a9e2d026e7da71161826cc01b9eaa8",
"type": "github"
},
"original": {
@ -670,23 +670,23 @@
},
"nixpkgs-lib": {
"locked": {
"lastModified": 1714640452,
"narHash": "sha256-QBx10+k6JWz6u7VsohfSw8g8hjdBZEf8CFzXH1/1Z94=",
"lastModified": 1717284937,
"narHash": "sha256-lIbdfCsf8LMFloheeE6N31+BMIeixqyQWbSr2vk79EQ=",
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz"
"url": "https://github.com/NixOS/nixpkgs/archive/eb9ceca17df2ea50a250b6b27f7bf6ab0186f198.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz"
"url": "https://github.com/NixOS/nixpkgs/archive/eb9ceca17df2ea50a250b6b27f7bf6ab0186f198.tar.gz"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1716061101,
"narHash": "sha256-H0eCta7ahEgloGIwE/ihkyGstOGu+kQwAiHvwVoXaA0=",
"lastModified": 1717265169,
"narHash": "sha256-IITcGd6xpNoyq9SZBigCkv4+qMHSqot0RDPR4xsZ2CA=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "e7cc61784ddf51c81487637b3031a6dd2d6673a2",
"rev": "3b1b4895b2c5f9f5544d02132896aeb9ceea77bc",
"type": "github"
},
"original": {
@ -714,11 +714,11 @@
},
"nixpkgs_3": {
"locked": {
"lastModified": 1716137900,
"narHash": "sha256-sowPU+tLQv8GlqtVtsXioTKeaQvlMz/pefcdwg8MvfM=",
"lastModified": 1716948383,
"narHash": "sha256-SzDKxseEcHR5KzPXLwsemyTR/kaM9whxeiJohbL04rs=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "6c0b7a92c30122196a761b440ac0d46d3d9954f1",
"rev": "ad57eef4ef0659193044870c731987a6df5cf56b",
"type": "github"
},
"original": {
@ -746,11 +746,11 @@
},
"nixpkgs_5": {
"locked": {
"lastModified": 1716062047,
"narHash": "sha256-OhysviwHQz4p2HZL4g7XGMLoUbWMjkMr/ogaR3VUYNA=",
"lastModified": 1717112898,
"narHash": "sha256-7R2ZvOnvd9h8fDd65p0JnB7wXfUvreox3xFdYWd1BnY=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "02923630b89aa1ab36ef8e422501a6f4fd4b2016",
"rev": "6132b0f6e344ce2fe34fc051b72fb46e34f668e0",
"type": "github"
},
"original": {
@ -762,11 +762,11 @@
},
"nur": {
"locked": {
"lastModified": 1716316781,
"narHash": "sha256-ybuEOdUtk7/X9GjZp72npoSk5GHT+9jpL7aPoXaTu7A=",
"lastModified": 1717300007,
"narHash": "sha256-rtggYfQX+ooy+5lXBOArmFiPmsemf5jLC8G9WKfGGM0=",
"owner": "nix-community",
"repo": "NUR",
"rev": "83bfd9ae2490c05fac7381100a13211cd27c3109",
"rev": "95edadf3f532643a9dbc55aa21f1fd3a01816007",
"type": "github"
},
"original": {
@ -801,11 +801,11 @@
"utils": "utils_2"
},
"locked": {
"lastModified": 1716315549,
"narHash": "sha256-WvNl8Mr9OJxTrk8uZ1v/Qqj9PRHL/xrRSuJqMSlfkG4=",
"lastModified": 1717300760,
"narHash": "sha256-dQIfOkT/gVzEcXjzQkRMuRhKEoddvZit2yj2kydl6TI=",
"owner": "xunuwu",
"repo": "small-nvim",
"rev": "7a3db695c926e9eb70d01efe8c29539200b2f306",
"rev": "040b84066cd6332d61c7d1b8ae571da8e74f75d8",
"type": "github"
},
"original": {
@ -820,11 +820,11 @@
"nixpkgs-stable": "nixpkgs-stable"
},
"locked": {
"lastModified": 1716244104,
"narHash": "sha256-XXbqfkyWe0d0O+zqRQWi2oXi6wYDmTzXedFkBRwx1VI=",
"lastModified": 1717297459,
"narHash": "sha256-cZC2f68w5UrJ1f+2NWGV9Gx0dEYmxwomWN2B0lx0QRA=",
"owner": "Mic92",
"repo": "sops-nix",
"rev": "fddd52460e3332eedd8a0043af5675338a5b3e0b",
"rev": "ab2a43b0d21d1d37d4d5726a892f714eaeb4b075",
"type": "github"
},
"original": {

View file

@ -23,7 +23,9 @@
name = "dots";
};
packages = import ./pkgs {inherit pkgs;};
packages = import ./pkgs {
inherit pkgs;
};
formatter = pkgs.alejandra;
};

View file

@ -7,6 +7,7 @@
../../terminal
../../terminal/programs/zellij.nix
../../terminal/programs/beets.nix
../../editors/nvim.nix
#../../editors/emacs.nix
../../editors/vscode.nix
@ -19,7 +20,8 @@
../../programs/desktop
../../programs/desktop/theme.nix
../../programs/desktop/awesome
../../programs/desktop/hyprland
#../../programs/desktop/hyprland
../../programs/desktop/sway
# development
../../develop

View file

@ -1,7 +1,7 @@
{
services.kanshi = {
enable = true;
systemdTarget = "hyprland-session.target";
# systemdTarget = "hyprland-session.target"; # default is sway
settings = [
{
profile.name = "default";

View file

@ -0,0 +1,24 @@
{
lib,
pkgs,
...
}: {
programs.fuzzel = {
enable = true;
settings = {
main = {
terminal = "${lib.getExe pkgs.foot}";
layer = "overlay";
};
colors = {
background = "#181818ff";
text = "#a4c6d9ff";
match = "#ae61b5ff";
border = "#feafffff";
selection = "#242424ff";
selection-text = "#ffffffff";
selection-match = "#fac1ffff";
};
};
};
}

View file

@ -0,0 +1,5 @@
{pkgs, ...}: {
home.packages = with pkgs; [
wl-clipboard
];
}

View file

@ -0,0 +1,5 @@
{
services.wob = {
enable = true;
};
}

View file

@ -2,13 +2,14 @@
xdg.portal = {
enable = true;
extraPortals = with pkgs; [
xdg-desktop-portal-hyprland
xdg-desktop-portal-kde
xdg-desktop-portal-wlr
xdg-desktop-portal-gtk
];
config = {
preferred = {
default = "hyprland;gtk";
"org.freedesktop.impl.portal.FileChooser" = "kde";
default = "gtk";
"org.freedesktop.impl.portal.Screenshot" = "wlr";
"org.freedesktop.impl.portal.Screencast" = "wlr";
};
};
};

View file

@ -1,10 +1,14 @@
{
pkgs,
lib,
inputs,
osConfig,
config,
...
}: {
imports = [
../common/fuzzel.nix
];
home.packages = with pkgs; [
wl-clipboard
];
@ -12,6 +16,7 @@
services.cliphist = {
enable = true;
systemdTarget = "hyprland-session.target";
extraOptions = ["-max-items" "150"];
};
#systemd.user.services.cliphist = {
# Unit = {
@ -31,24 +36,6 @@
# WantedBy = ["hyprland-session.target"];
# };
#};
programs.fuzzel = {
enable = true;
settings = {
main = {
terminal = "${lib.getExe pkgs.foot}";
layer = "overlay";
};
colors = {
background = "#181818ff";
text = "#a4c6d9ff";
match = "#ae61b5ff";
border = "#feafffff";
selection = "#242424ff";
selection-text = "#ffffffff";
selection-match = "#fac1ffff";
};
};
};
programs.waybar = {
enable = true;
@ -183,7 +170,7 @@
};
"clock" = {
"tooltim-format" = "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>";
"format-alt" = "{:%Y-%m-%d}";
"format-alt" = "{:%a %Y-%m-%d}";
};
"pulseaudio" = {
"format" = "{volume}%";
@ -214,7 +201,7 @@
settings = {
exec-once = [
#"${lib.getExe pkgs.xwaylandvideobridge}"
"${lib.getExe pkgs.swaybg} -i ${config.xdg.userDirs.pictures}/wallpaper.png"
"${lib.getExe pkgs.swaybg} -i ${config.xdg.userDirs.pictures}/wallpaper"
];
env = [
"NIXOS_OZONE_WL,1" # for any ozone-based browser & electron apps to run on wayland
@ -229,7 +216,7 @@
];
input = {
kb_layout = "eu";
kb_layout = osConfig.services.xserver.xkb.layout;
};
general = {
@ -273,6 +260,7 @@
"$mainMod, P, exec, ${lib.getExe pkgs.fuzzel}"
"$mainMod SHIFT, V, exec, ${lib.getExe pkgs.cliphist} list | ${lib.getExe pkgs.wofi} --dmenu | ${lib.getExe pkgs.cliphist} decode | ${pkgs.wl-clipboard}/bin/wl-copy"
"$mainMod SHIFT, S, exec, ${lib.getExe pkgs.grimblast} --freeze copy area"
"$mainMod SHIFT, BACKSPACE, exec, systemctl suspend"
"$mainMod, N, togglesplit"
"$mainMod SHIFT, N, swapsplit"

View file

@ -0,0 +1,99 @@
{
config,
pkgs,
lib,
osConfig,
...
}: {
imports = [
../common/fuzzel.nix
../common/wob.nix
../common/wl-clipboard.nix
];
services.cliphist = {
enable = true;
systemdTarget = "sway-session.target";
extraOptions = ["-max-items" "150"];
};
wayland.windowManager.sway = {
enable = true;
checkConfig = false; # doesnt work with custom wallpaper
config = {
modifier = "Mod4";
output = {
"*".bg = "${config.xdg.userDirs.pictures}/wallpaper fill";
};
input = {
"*".xkb_layout = osConfig.services.xserver.xkb.layout;
};
bars = [
{
workspaceNumbers = false;
statusCommand = "${lib.getExe pkgs.i3status}";
}
];
keybindings = let
mod = config.wayland.windowManager.sway.config.modifier;
wobVolume = "${pkgs.wireplumber}/bin/wpctl get-volume @DEFAULT_SINK@ | awk '{print $2*100}' > $XDG_RUNTIME_DIR/wob.sock";
setVolume = limit: amount: "${pkgs.wireplumber}/bin/wpctl set-volume -l ${limit} @DEFAULT_AUDIO_SINK@ ${amount}";
perMonitor = workspace: "\"$(${config.wayland.windowManager.sway.package}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[] | select(.focused == true).id')${toString workspace}\"";
#perMonitor = workspace: "${lib.getExe (pkgs.writeShellScriptBin "perMonitor" ''
# id=$( md5sum <<< ${config.wayland.windowManager.sway.package}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[] | select(.focused == true).id' )
# echo $((0x''${id%% *}))
#'')} workspace";
#perMonitor = pkgs.writeShellScriptBin "perMonitor" ''
# args=( "$@" )
# id=$( ${config.wayland.windowManager.sway.package}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[] | select(.focused == true).id' )
# # args[$#-1]=$(( ''${args[$#-1]} + $id * 10 ))
# args[$#-1]="$id:''${args[$#-1]}"
# swaymsg ''${args[@]}
#'';
dir = with config.wayland.windowManager.sway.config; {
inherit up down left right;
};
in
lib.mkOptionDefault (
{
"${mod}+Shift+v" = "exec ${lib.getExe pkgs.cliphist} list | ${lib.getExe pkgs.wofi} --dmenu | ${lib.getExe pkgs.cliphist} decode | ${pkgs.wl-clipboard}/bin/wl-copy";
"${mod}+Ctrl+${dir.left}" = "focus output left";
"${mod}+Ctrl+${dir.right}" = "focus output right";
"${mod}+Ctrl+${dir.up}" = "focus output up";
"${mod}+Ctrl+${dir.down}" = "focus output down";
"${mod}+Ctrl+Shift+${dir.left}" = "move output left";
"${mod}+Ctrl+Shift+${dir.right}" = "move output right";
"${mod}+Ctrl+Shift+${dir.up}" = "move output up";
"${mod}+Ctrl+Shift+${dir.down}" = "move output down";
"${mod}+d" = "exec ${lib.getExe pkgs.fuzzel}";
"${mod}+Shift+Backspace" = "exec systemctl suspend";
"${mod}+Shift+s" = "exec ${lib.getExe pkgs.grimblast} copy area";
"XF86AudioRaiseVolume" = "exec ${setVolume "1.5" "3%+"} && ${wobVolume}";
"XF86AudioLowerVolume" = "exec ${setVolume "1.5" "3%-"} && ${wobVolume}";
"XF86AudioPlay" = "exec ${lib.getExe pkgs.playerctl} play-pause";
"XF86AudioStop" = "exec ${lib.getExe pkgs.playerctl} stop";
"XF86AudioNext" = "exec ${lib.getExe pkgs.playerctl} next";
"XF86AudioPrev" = "exec ${lib.getExe pkgs.playerctl} previous";
}
// builtins.listToAttrs (lib.flatten
(builtins.map (x: [
{
name = "${mod}+${toString x}";
#value = "exec swaymsg workspace ${toString x}";
value = "exec swaymsg workspace number ${perMonitor x} ${toString x}";
#value = "exec ${lib.getExe perMonitor} workspace ${toString x}";
}
{
name = "${mod}+Shift+${toString x}";
#value = "exec swaymsg move workspace ${toString x}";
value = "exec swaymsg move container to workspace number ${perMonitor x} ${toString x}";
#value = "exec ${lib.getExe perMonitor} move workspace ${toString x}";
}
]) (lib.range 0 9)))
);
};
};
}

View file

@ -7,6 +7,9 @@
size = 16;
};
# Also sets org.freedesktop.appearance color-scheme
dconf.settings."org/gnome/desktop/interface".color-scheme = "prefer-dark";
gtk = {
enable = true;
theme = {
@ -21,6 +24,9 @@
name = "Sans";
size = 11;
};
gtk2.extraConfig = "gtk-application-prefer-dark-theme=1";
gtk3.extraConfig.gtk-application-prefer-dark-theme = 1;
gtk4.extraConfig.gtk-application-prefer-dark-theme = 1;
};
qt = {

View file

@ -2,5 +2,6 @@
home.packages = with pkgs; [
jellyfin-media-player
sonixd
feishin
];
}

View file

@ -1,17 +1,6 @@
{pkgs, ...}: {
home.packages = with pkgs; [
# TODO: remove this once the vesktop screenshare update gets released
(vesktop.overrideAttrs (final: prev: {
version = "ab9e8579eea046187c5cdb51e2041a0beb6e8601";
src = pkgs.fetchgit {
url = "https://github.com/Vencord/Vesktop.git";
rev = "ab9e8579eea046187c5cdb51e2041a0beb6e8601";
hash = "sha256-s3ndHHN8mqbzL40hMDXXDl+VV9pOk4XfnaVCaQvFFsg=";
};
pnpmDeps = prev.pnpmDeps.overrideAttrs {
outputHash = "sha256-6ezEBeYmK5va3gCh00YnJzZ77V/Ql7A3l/+csohkz68=";
};
}))
vesktop
(discord.override {
withVencord = true;
withOpenASAR = true;

View file

@ -1,3 +1,4 @@
# TODO fix polkit, this dosent work
{pkgs, ...}: {
systemd.user.services.polkit-gnome-authentication-agent-1 = {
Unit.Description = "polkit-gnome-authentication-agent-1";

View file

@ -0,0 +1,83 @@
let
musicDir = "/home/xun/music/library";
in {
programs.beets = {
enable = true;
settings = {
directory = "${musicDir}/data";
library = "${musicDir}/beets/beets.db";
import = {
log = "${musicDir}/beets/import.log";
incremental = true;
};
plugins = [
"embedart"
"fetchart"
"discogs"
#"advancedrewrite"
"lyrics"
"spotify"
"scrub"
"duplicates"
"unimported"
];
genres = true;
spotify.source_weight = 0.7;
embedart = {
auto = true;
ifempty = false;
remove_art_file = false;
};
fetchart = {
auto = true;
cautious = true;
minwidth = 500;
maxwidth = 1200;
cover_format = "jpeg";
sources = [
{"coverart" = "release";}
{"coverart" = "releasegroup";}
"albumart"
"amazon"
"google"
"itunes"
"fanarttv"
"lastfm"
"wikipedia"
];
lyrics = {
fallback = "''";
sources = ["musicmatch" "google"];
};
replace = {
"[\\\\]" = "'";
"[_]" = "-";
"[\\]" = "-";
"^\\." = "'";
"[\\x00-\\x1f]" = "'";
"[<>:\"\\?\\*\\|]" = "'";
"\\.$" = "'";
"\\s+$" = "'";
"^\\s+" = "'";
"^-" = "'";
"" = "'";
"" = "'";
"" = "'";
"" = "-";
};
aunique = {
keys = ["albumartist" "albumtype" "year" "album"];
disambuguators = ["format" "mastering" "media" "label" "albumdisambig" "releasegroupdisambig"];
bracket = "[]";
};
};
};
};
}

View file

@ -9,6 +9,8 @@
bind '"' split-window -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
bind c new-window -c "#{pane_current_path}";
set-option -g status-style bg=default
'';
};
}

View file

@ -23,6 +23,9 @@
# improve ^w behaviour
WORDCHARS=
# pretty completion menu
zstyle ':completion:*' menu select
# shift-tab in completion menu
bindkey '^[[Z' reverse-menu-complete

View file

@ -30,7 +30,7 @@
serviceConfig = {
StandardInput = "socket";
ExecStart = "${pkgs.writeShellScript "brawlstats-web.sh" ''
parameters=$(head -n1 | ${lib.getExe pkgs.gawk} '{print $2}' | ${lib.getExe pkgs.gnused} 's/%20/ /g')
parameters=$(head -n1 | ${lib.getExe pkgs.gawk} '{print $2}' | ${lib.getExe pkgs.gnused} 's/,/ /g')
response=""
tosvg() {

View file

@ -7,9 +7,15 @@
./brawlstats.nix
];
services.tailscale.extraUpFlags = [
"--ssh"
];
networking.hostName = "hopper";
swapDevices = [];
networking.interfaces.eno1.wakeOnLan.enable = true;
system.stateVersion = "23.11";
}

View file

@ -1,4 +1,5 @@
{pkgs, ...}: {
jdnbtexplorer = pkgs.qt6Packages.callPackage ./jdnbtexplorer {};
gamesand = pkgs.callPackage ./gamesand {};
pince = pkgs.callPackage ./pince {};
}

132
pkgs/pince/default.nix Normal file
View file

@ -0,0 +1,132 @@
{
lib,
python3,
python3Packages,
wrapGAppsHook,
gobject-introspection,
gtk3,
cmake,
fetchgit,
qt6,
git,
gdb,
xorg,
xcb-util-cursor,
}: let
libptrscan = builtins.fetchTarball {
url = "https://github.com/kekeimiku/PointerSearcher-X/releases/download/v0.7.3-dylib/libptrscan_pince-x86_64-unknown-linux-gnu.tar.gz";
sha256 = "sha256:1as9hjp1xf3mfsxyaw5lxibmxr73nhnbgsxabvg34df7g9ihfq3f";
};
in
python3Packages.buildPythonApplication rec {
pname = "PINCE";
version = "0.1";
format = "other";
#src = fetchFromGitHub {
# owner = "korcankaraokcu";
# repo = "PINCE";
# rev = "823b213c531d9ffda1aa2b6504bc8a9eefc0c27f";
# hash = "sha256-4MTdr4++1tVfXg/t58kcILi2zS83T4IwqgKKXh0Kx3Q=";
#};
src = fetchgit {
url = "https://github.com/korcankaraokcu/PINCE";
rev = "823b213c531d9ffda1aa2b6504bc8a9eefc0c27f";
hash = "sha256-5jcxWMJHoqCIFLgMyygZ3uh5WfkD0pjiqWg1iKzdwZc=";
leaveDotGit = true;
};
dontUseCmakeConfigure = true;
dontWrapPythonPrograms = true;
dontWrapGApps = true;
patchPhase = ''
# Remove ".venv/PINCE" exist check
sed -i '/^if \[ ! -d "\.venv\/PINCE" \]; /,/activate$/ s/^/# /' "./PINCE.sh"
sed -i '$s/.venv\/PINCE\/bin\/python3/${lib.escape ["/"] (toString python3)}\/bin\/python3/g' "./PINCE.sh"
sed -i 's/#!\/bin\/bash/#!\/bin\/sh/' "./PINCE.sh"
sed -i 's/\/bin\/gdb/gdb/g' "libpince/typedefs.py"
# Create a simple start script
cat > pince <<- SHELL
#!/usr/bin/env bash
sh PINCE.sh "\$@"
read -p "Press enter to exit..."
SHELL
'';
buildPhase = ''
runHook preBuild
sed -i 's/git submodule.*//g' install.sh
. <(sed -n '/^exit_on_error() /,/^}/p' install.sh)
. <(sed -n '/^set_install_vars() /,/^}/p' install.sh)
. <(sed -n '/^compile_translations() /,/^}/p' install.sh)
. <(sed -n '/^compile_libscanmem() /,/^}/p' install.sh)
. <(sed -n '/^install_libscanmem() /,/^}/p' install.sh)
install_libscanmem || exit_on_error
mkdir -p libpince/libptrscan
cp ${libptrscan}/ptrscan.py libpince/libptrscan/
cp ${libptrscan}/libptrscan_pince.so libpince/libptrscan/libptrscan.so
LRELEASE_CMD=${qt6.qttools}/bin/lrelease compile_translations || exit_on_error
runHook postBuild
'';
fixupPhase = ''
runHook preFixup
makeWrapper ${lib.getExe python3} $out/bin/PINCE \
"''${gappsWrapperArgs[@]}" \
--set PYTHONPATH "${python3Packages.makePythonPath (with python3Packages; [
pexpect
pyqt6
distorm3
keystone-engine
pygdbmi
keyboard
pygobject3
])}" \
--suffix PATH : "${lib.makeBinPath [
gdb
qt6.full
]}" \
--add-flags "$out/share/pince/PINCE.py"
runHook postFixup
'';
nativeBuildInputs = [
wrapGAppsHook
git
cmake
gobject-introspection
];
buildInputs = [
python3
];
propagatedBuildInputs = with python3Packages; [
qt6.full
xorg.libxcb
xcb-util-cursor
gtk3
pyqt6
pexpect
distorm3
keystone-engine
pygdbmi
keyboard
pygobject3
gdb
];
installPhase = ''
mkdir -p $out/share/pince
cp -r . $out/share/pince
'';
}

View file

@ -11,6 +11,7 @@ let
./network/networkd.nix
./network/avahi.nix
./network/localsend.nix
./network/tailscale.nix
./desktop

View file

@ -0,0 +1,8 @@
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
localsend
];
networking.firewall.allowedTCPPorts = [53317];
networking.firewall.allowedUDPPorts = [53317];
}

View file

@ -6,6 +6,7 @@
}: {
environment.systemPackages = [
pkgs.protontricks
pkgs.steamtinkerlaunch
];
programs.steam = {

View file

@ -1,10 +1,4 @@
{
config,
pkgs,
lib,
inputs,
...
}: {
{config, ...}: {
imports = [
#./smbshare.nix
];
@ -104,7 +98,7 @@
];
};
jellyfin = {
image = "jellyfin/jellyfin";
image = "jellyfin/jellyfin:2024052005";
volumes = [
"/media/config/jellyfin/config:/config"
"/media/config/jellyfin/cache:/cache"
@ -313,6 +307,8 @@
lyrics,
spotify,
scrub,
duplicates,
unimported,
]
genres: yes
@ -320,9 +316,6 @@
spotify:
source_weight: 0.7
advancesrewrite:
artist GHOST: Ghost and Pals
embedart:
auto: yes
ifempty: no

View file

@ -15,7 +15,7 @@
autoAcceptFolders = true;
};
"redmi-note-10-pro" = {
id = "MRAHIKH-TNHAKEG-OHMEFXI-BO54SXR-6IL2Y3B-3HVOWZF-ZGTS2OX-YSWTPQF";
id = "WJPE56U-56LPOYB-IAENGSW-IFQ4A6J-66JX73I-ONXX4PY-QXJK6IF-UZHVWA7";
autoAcceptFolders = true;
};
"hopper" = {
@ -26,11 +26,19 @@
folders = {
"~/secrets" = {
devices = builtins.attrNames config.services.syncthing.settings.devices;
versioning = {
type = "trashcan";
params.cleanoutDays = "180";
};
id = "sfw9y-yusup";
};
"~/docs/xun-megavault" = {
devices = builtins.attrNames config.services.syncthing.settings.devices;
id = "1zkf-wf5r";
versioning = {
type = "simple";
params.keep = "15";
};
};
};
};