Compare commits
2 commits
ae65d2e808
...
3c34e87a80
| Author | SHA1 | Date | |
|---|---|---|---|
| 3c34e87a80 | |||
| 68a0395d9a |
2 changed files with 59 additions and 0 deletions
|
|
@ -15,6 +15,9 @@ in {
|
||||||
"n8n"
|
"n8n"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
overlays = [
|
||||||
|
(import ../../utils/overlays/packages.nix)
|
||||||
|
];
|
||||||
};
|
};
|
||||||
config = {
|
config = {
|
||||||
microvm = {
|
microvm = {
|
||||||
|
|
|
||||||
|
|
@ -18,5 +18,61 @@ self: super: {
|
||||||
|
|
||||||
pyload-ng = self.callPackage ../pkgs/pyload-ng { pyload-ng = super.pyload-ng; };
|
pyload-ng = self.callPackage ../pkgs/pyload-ng { pyload-ng = super.pyload-ng; };
|
||||||
|
|
||||||
|
# TODO: Remove this override once nixpkgs includes invidious >= 2.20250204 with PR #5614 fix
|
||||||
|
# Fix for 400 errors on channel lists - https://github.com/iv-org/invidious/pull/5614
|
||||||
|
invidious =
|
||||||
|
let
|
||||||
|
version = "unstable-2026-02-04";
|
||||||
|
commit = "ecbc21b";
|
||||||
|
date = "2026.02.04";
|
||||||
|
src = super.fetchFromGitHub {
|
||||||
|
owner = "iv-org";
|
||||||
|
repo = "invidious";
|
||||||
|
rev = "ecbc21b0678eac4a0c8f745de5cc78eef4841221";
|
||||||
|
fetchSubmodules = true;
|
||||||
|
hash = "sha256-S6/d1Fzv3CrZHBW3aE21OoPUeQwEFFMwkeJyUKyTcGQ=";
|
||||||
|
};
|
||||||
|
# Fetch videojs dependencies - reuse existing hash as dependencies are unlikely to change
|
||||||
|
videojs = super.stdenvNoCC.mkDerivation {
|
||||||
|
name = "videojs";
|
||||||
|
inherit src;
|
||||||
|
builder = "${super.path}/pkgs/by-name/in/invidious/videojs.sh";
|
||||||
|
nativeBuildInputs = with super; [ cacert crystal_1_16 openssl pkg-config ];
|
||||||
|
outputHashAlgo = "sha256";
|
||||||
|
outputHashMode = "recursive";
|
||||||
|
outputHash = "sha256-jED3zsDkPN8i6GhBBJwnsHujbuwlHdsVpVqa1/pzSH4=";
|
||||||
|
};
|
||||||
|
in
|
||||||
|
super.invidious.overrideAttrs (oldAttrs: {
|
||||||
|
inherit version src;
|
||||||
|
postPatch = let
|
||||||
|
branchTemplate = ''{{ "#{`git branch | sed -n '/* /s///p'`.strip}" }}'';
|
||||||
|
commitTemplate = ''{{ "#{`git rev-list HEAD --max-count=1 --abbrev-commit`.strip}" }}'';
|
||||||
|
versionTemplate = ''{{ "#{`git log -1 --format=%ci | awk '{print $1}' | sed s/-/./g`.strip}" }}'';
|
||||||
|
tagTemplate = ''{{ "#{`git tag --points-at HEAD`.strip}" }}'';
|
||||||
|
assetCommitTemplate = ''{{ "#{`git rev-list HEAD --max-count=1 --abbrev-commit -- assets`.strip}" }}'';
|
||||||
|
in ''
|
||||||
|
for d in ${videojs}/*; do ln -s "$d" assets/videojs; done
|
||||||
|
|
||||||
|
substituteInPlace src/invidious.cr \
|
||||||
|
--replace-fail ${super.lib.escapeShellArg branchTemplate} '"master"' \
|
||||||
|
--replace-fail ${super.lib.escapeShellArg commitTemplate} '"${commit}"' \
|
||||||
|
--replace-fail ${super.lib.escapeShellArg versionTemplate} '"${date}"' \
|
||||||
|
--replace-fail ${super.lib.escapeShellArg tagTemplate} '""' \
|
||||||
|
--replace-fail ${super.lib.escapeShellArg assetCommitTemplate} '"${commit}"'
|
||||||
|
|
||||||
|
substituteInPlace src/invidious.cr \
|
||||||
|
--replace-fail 'public_folder "assets"' 'public_folder "${placeholder "out"}/share/invidious/assets"'
|
||||||
|
substituteInPlace src/invidious/helpers/i18n.cr \
|
||||||
|
--replace-fail 'File.read("locales/' 'File.read("${placeholder "out"}/share/invidious/locales/'
|
||||||
|
|
||||||
|
substituteInPlace src/invidious/database/base.cr \
|
||||||
|
--replace-fail 'config/sql' '${placeholder "out"}/share/invidious/config/sql'
|
||||||
|
|
||||||
|
substituteInPlace src/invidious/user/captcha.cr \
|
||||||
|
--replace-fail 'Process.run(%(rsvg-convert' 'Process.run(%(${super.lib.getBin super.librsvg}/bin/rsvg-convert'
|
||||||
|
'';
|
||||||
|
});
|
||||||
|
|
||||||
# vscode-insiders = (super.callPackage ../pkgs/vscode-insiders.nix { });
|
# vscode-insiders = (super.callPackage ../pkgs/vscode-insiders.nix { });
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue