refactor(mpris scripts): move src to flake.nix
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2024-01-01 17:34:49 -05:00
parent 19e87de889
commit 8e69d3375d
10 changed files with 25 additions and 44 deletions

Binary file not shown.

BIN
flake.nix

Binary file not shown.

View file

@ -1,4 +1,4 @@
{pkgs, ...}: { {pkgs, ...} @ inputs: {
# For kdialog-open-files # For kdialog-open-files
home.packages = with pkgs; [ home.packages = with pkgs; [
kdialog kdialog
@ -8,7 +8,7 @@
enable = true; enable = true;
# https://github.com/mpv-player/mpv/wiki/User-Scripts # https://github.com/mpv-player/mpv/wiki/User-Scripts
scripts = with (import ./scripts pkgs); [ scripts = with (import ./scripts inputs); [
modernx modernx
# Dep of touch-gestures # Dep of touch-gestures
pointer-event pointer-event

View file

@ -1,10 +1,10 @@
{pkgs, ...}: let {pkgs, ...} @ inputs: let
buildLua = buildLua =
pkgs.callPackage pkgs.callPackage
"${pkgs.path}/pkgs/applications/video/mpv/scripts/buildLua.nix" {}; "${pkgs.path}/pkgs/applications/video/mpv/scripts/buildLua.nix" {};
buildLuaScript = file: buildLuaScript = file:
pkgs.callPackage file {inherit buildLua;}; pkgs.callPackage file (inputs // {inherit buildLua;});
in in
pkgs.recurseIntoAttrs { pkgs.recurseIntoAttrs {
modernx = buildLuaScript ./modernx.nix; modernx = buildLuaScript ./modernx.nix;

View file

@ -1,6 +1,7 @@
{ {
fetchurl, fetchurl,
buildLua, buildLua,
...
}: }:
buildLua rec { buildLua rec {
pname = "zenity-open-files"; pname = "zenity-open-files";

View file

@ -1,18 +1,14 @@
{ {
fetchFromGitHub, modernx-src,
makeFontsConf, makeFontsConf,
buildLua, buildLua,
...
}: }:
buildLua (finalAttrs: { buildLua (finalAttrs: {
pname = "modernx"; pname = "modernx";
version = "unstable"; version = modernx-src.rev;
src = fetchFromGitHub { src = modernx-src;
owner = "cyl0";
repo = "ModernX";
rev = "d053ea602d797bdd85d8b2275d7f606be067dc21";
hash = "sha256-Gpofl529VbmdN7eOThDAsNfNXNkUDDF82Rd+csXGOQg=";
};
# Make font available to script # Make font available to script
postInstall = '' postInstall = ''

View file

@ -1,15 +1,11 @@
{ {
fetchFromGitHub, persist-properties-src,
buildLua, buildLua,
...
}: }:
buildLua { buildLua {
pname = "persist-properties"; pname = "persist-properties";
version = "unstable"; version = persist-properties-src.rev;
src = fetchFromGitHub { src = persist-properties-src;
owner = "d87";
repo = "mpv-persist-properties";
rev = "ddb1e6bd7a7d57da9b567ea8dc5227906f416ec6";
hash = "sha256-C2nejhkxAZgfKRl9FrZZqODq2xW6zCbv/sBiqXSAd2k=";
};
} }

View file

@ -1,15 +1,11 @@
{ {
fetchFromGitHub, pointer-event-src,
buildLua, buildLua,
...
}: }:
buildLua { buildLua {
pname = "pointer-event"; pname = "pointer-event";
version = "unstable"; version = pointer-event-src.rev;
src = fetchFromGitHub { src = pointer-event-src;
owner = "christoph-heinrich";
repo = "mpv-pointer-event";
rev = "33c5ede5977817596ace5a9942a8c801ad3b3d28";
hash = "sha256-h2E8wiQX2Vh9qyi2VsXzeOE5vnD9Xin5HZ2Wu2LZUOY=";
};
} }

View file

@ -1,15 +1,11 @@
{ {
fetchFromGitHub, touch-gestures-src,
buildLua, buildLua,
...
}: }:
buildLua { buildLua {
pname = "touch-gestures"; pname = "touch-gestures";
version = "unstable"; version = touch-gestures-src.rev;
src = fetchFromGitHub { src = touch-gestures-src;
owner = "christoph-heinrich";
repo = "mpv-touch-gestures";
rev = "f4aa499f038997c1824ff3bfa64ee1d5438d72f2";
hash = "sha256-gmo6sTwN85WS/+wtlylfI22LxyZH48DvXYP5JGCnyU4=";
};
} }

View file

@ -1,16 +1,12 @@
{ {
fetchFromGitHub, eisa-scripts-src,
buildLua, buildLua,
...
}: }:
buildLua rec { buildLua rec {
pname = "undo-redo"; pname = "undo-redo";
version = "unstable"; version = eisa-scripts-src.rev;
src = fetchFromGitHub { src = eisa-scripts-src;
owner = "Eisa01";
repo = "mpv-scripts";
rev = "48d68283cea47ff8e904decc9003b3abc3e2123e";
hash = "sha256-95CAKjBRELX2f7oWSHFWJnI0mikAoxhfUphe9k51Qf4=";
};
scriptPath = "${src}/scripts/UndoRedo.lua"; scriptPath = "${src}/scripts/UndoRedo.lua";
} }