Add flakes support

This commit is contained in:
Martin Potier 2021-10-08 15:59:27 +03:00
parent 4b8e0a0cd7
commit 73e0054724
No known key found for this signature in database
GPG Key ID: D4DD957DBA4AD89E
3 changed files with 57 additions and 23 deletions

25
flake.lock Normal file
View File

@ -0,0 +1,25 @@
{
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1633695537,
"narHash": "sha256-mZXHU2Ue0wHyxL4l+22BtcPpFlGUtYLZK7o7fP39yfc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b27d18a412b071f5d7991d1648cfe78ee7afe68a",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

9
flake.nix Normal file
View File

@ -0,0 +1,9 @@
{
description = "My overlays";
outputs = { self, nixpkgs }: {
overlay = import ./pkgs;
};
}

View File

@ -1,9 +1,9 @@
# This overlay provides a set of customized pkgs. # This overlay provides a set of customized pkgs.
self: super: final: prev:
{ {
iosevka-hskl = super.iosevka.override { iosevka-hskl = prev.iosevka.override {
privateBuildPlan = '' privateBuildPlan = ''
[buildPlans.iosevka-samae] [buildPlans.iosevka-samae]
family = "Iosevka Samae" family = "Iosevka Samae"
@ -53,49 +53,49 @@ self: super:
set = "samae"; set = "samae";
}; };
wineNoGS = super.wineStaging.override { gstreamerSupport = false; }; wineNoGS = prev.wineStaging.override { gstreamerSupport = false; };
surge-samae = super.callPackage ./surge {}; surge-samae = prev.callPackage ./surge {};
carla-samae = super.qt5.callPackage ./carla {}; carla-samae = prev.qt5.callPackage ./carla {};
vim-samae = super.callPackage ./vim {}; vim-samae = prev.callPackage ./vim {};
patchmatrix-samae = super.callPackage ./patchmatrix {}; patchmatrix-samae = prev.callPackage ./patchmatrix {};
reaper-samae = super.callPackage ./reaper {}; reaper-samae = prev.callPackage ./reaper {};
mopidy-mpd-samae = super.callPackage ./mopidy-mpd {}; mopidy-mpd-samae = prev.callPackage ./mopidy-mpd {};
vcv-rack-samae = super.callPackage ./vcv-rack {}; vcv-rack-samae = prev.callPackage ./vcv-rack {};
scientifica-font = super.callPackage ./scientifica-font {}; scientifica-font = prev.callPackage ./scientifica-font {};
curie-font = super.callPackage ./curie-font {}; curie-font = prev.callPackage ./curie-font {};
victor-mono = super.callPackage ./victor-mono {}; victor-mono = prev.callPackage ./victor-mono {};
ripmime = super.ripmime.override { ripmime = prev.ripmime.override {
stdenv = super.overrideCC super.stdenv super.gcc6; stdenv = prev.overrideCC prev.stdenv prev.gcc6;
}; };
squeezer = super.callPackage ./squeezer {}; squeezer = prev.callPackage ./squeezer {};
decentsampler = super.callPackage ./decentsampler {}; decentsampler = prev.callPackage ./decentsampler {};
# Originally from Mats Rauhala ®2018 # Originally from Mats Rauhala ®2018
copy = super.writeScriptBin "copy" '' copy = prev.writeScriptBin "copy" ''
function clean() { function clean() {
sleep 10 sleep 10
${super.libnotify}/bin/notify-send -u low 'Clipboard cleaned' ${prev.libnotify}/bin/notify-send -u low 'Clipboard cleaned'
${super.xclip}/bin/xclip -sel clipboard -i /dev/null ${prev.xclip}/bin/xclip -sel clipboard -i /dev/null
} }
${super.xclip}/bin/xclip -sel clipboard < /dev/stdin ${prev.xclip}/bin/xclip -sel clipboard < /dev/stdin
${super.libnotify}/bin/notify-send -u low -t 10000 'Clipboard set' ${prev.libnotify}/bin/notify-send -u low -t 10000 'Clipboard set'
clean & clean &
''; '';
myAt = super.writeScriptBin "at" '' myAt = prev.writeScriptBin "at" ''
echo "Running cmd in $(( $(date -d "$1" +%s) - $(date +%s) )) seconds" echo "Running cmd in $(( $(date -d "$1" +%s) - $(date +%s) )) seconds"
sleep $(( $(date -d "$1" +%s) - $(date +%s) )) sleep $(( $(date -d "$1" +%s) - $(date +%s) ))
shift 1 shift 1