mirror of
https://github.com/tomasriveral/nixos.git
synced 2026-08-12 10:30:44 +02:00
Manual derivation for Vivify 0.14.0 (which is still not on unstable
This commit is contained in:
@@ -227,7 +227,6 @@
|
|||||||
]))
|
]))
|
||||||
iamb # matrix client
|
iamb # matrix client
|
||||||
direnv
|
direnv
|
||||||
vivify # for nvimnotes
|
|
||||||
# utils for dev
|
# utils for dev
|
||||||
pkg-config
|
pkg-config
|
||||||
gdb
|
gdb
|
||||||
@@ -258,6 +257,13 @@
|
|||||||
papirus-folders
|
papirus-folders
|
||||||
inkscape
|
inkscape
|
||||||
birdtray # thunderbird tray app
|
birdtray # thunderbird tray app
|
||||||
|
#vivify # for NoteWrapper
|
||||||
|
# this is more up to date
|
||||||
|
(callPackage ../../modules/packages/vivify.nix {})
|
||||||
|
(callPackage ../../modules/packages/sbb-tui.nix {})
|
||||||
|
pkgs-unstable.nixpkgs-review
|
||||||
|
pkgs-unstable.nixfmt-tree
|
||||||
|
pkgs-unstable.treefmt
|
||||||
];
|
];
|
||||||
|
|
||||||
# fonts
|
# fonts
|
||||||
|
|||||||
@@ -84,6 +84,7 @@
|
|||||||
(pkgs.callPackage ../../modules/scripts/man.nix {})
|
(pkgs.callPackage ../../modules/scripts/man.nix {})
|
||||||
(pkgs.callPackage ../../modules/scripts/trimmer.nix {})
|
(pkgs.callPackage ../../modules/scripts/trimmer.nix {})
|
||||||
(pkgs.callPackage ../../modules/qt/qtbatticon.nix {})
|
(pkgs.callPackage ../../modules/qt/qtbatticon.nix {})
|
||||||
|
|
||||||
#(pkgs.callPackage ../../modules/scripts/obsidianbackup.nix {}) # periodically syncs obsidian's note to kdrive
|
#(pkgs.callPackage ../../modules/scripts/obsidianbackup.nix {}) # periodically syncs obsidian's note to kdrive
|
||||||
#(pkgs.callPackage ../../modules/scripts/obsidianprofiles.nix {}) # fzf vault selector # obsidian was replaced with a custom solution
|
#(pkgs.callPackage ../../modules/scripts/obsidianprofiles.nix {}) # fzf vault selector # obsidian was replaced with a custom solution
|
||||||
# no longer used scripts for quickshell. see caelestia-shell
|
# no longer used scripts for quickshell. see caelestia-shell
|
||||||
|
|||||||
@@ -0,0 +1,3 @@
|
|||||||
|
Used for custom package derivation.
|
||||||
|
|
||||||
|
For example, to use a newer package version that is still not in nixpkgs-unstable.
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
{ lib
|
||||||
|
, buildGoModule
|
||||||
|
, fetchFromGitHub
|
||||||
|
, nix-update-script
|
||||||
|
}:
|
||||||
|
|
||||||
|
buildGoModule rec {
|
||||||
|
pname = "sbb-tui";
|
||||||
|
version = "1.13.4";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "Necrom4";
|
||||||
|
repo = "sbb-tui";
|
||||||
|
rev = "v${version}";
|
||||||
|
sha256 = "sha256-JLjAhs5UbqgNYqpA3cDucrAS6ell+0JiDJNf7G33Nhs=";
|
||||||
|
};
|
||||||
|
|
||||||
|
vendorHash = "sha256-K4DOu3rfSlKAa5JNKCzWWpnWZlXXxtN5Po7p1Spqe1w=";
|
||||||
|
|
||||||
|
ldflags = [
|
||||||
|
"-s"
|
||||||
|
"-w"
|
||||||
|
];
|
||||||
|
|
||||||
|
doCheck = true;
|
||||||
|
|
||||||
|
passthru.updateScript = nix-update-script { };
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "TUI client for Switzerland's public transport timetables, inspired by SBB/CFF/FFS app";
|
||||||
|
homepage = "https://github.com/Necrom4/sbb-tui";
|
||||||
|
license = licenses.mit;
|
||||||
|
platforms = platforms.unix;
|
||||||
|
maintainers = with maintainers; [ tomasrivera ];
|
||||||
|
mainProgram = "sbb-tui";
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,88 @@
|
|||||||
|
{
|
||||||
|
lib,
|
||||||
|
stdenv,
|
||||||
|
nix-update-script,
|
||||||
|
fetchYarnDeps,
|
||||||
|
fetchFromGitHub,
|
||||||
|
yarnConfigHook,
|
||||||
|
npmHooks,
|
||||||
|
nodejs,
|
||||||
|
zip,
|
||||||
|
file,
|
||||||
|
}:
|
||||||
|
|
||||||
|
stdenv.mkDerivation (finalAttrs: {
|
||||||
|
pname = "vivify";
|
||||||
|
version = "0.14.0";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "jannis-baum";
|
||||||
|
repo = "Vivify";
|
||||||
|
tag = "v${finalAttrs.version}";
|
||||||
|
hash = "sha256-CszMG+c0bNHfXWqcI3b4iGpeFJ+FmzHDzxflPS+wEe0=";
|
||||||
|
};
|
||||||
|
|
||||||
|
yarnOfflineCache = fetchYarnDeps {
|
||||||
|
yarnLock = "${finalAttrs.src}/yarn.lock";
|
||||||
|
hash = "sha256-svgEanFiBSQn0TdTuB0CnLR71lkANABEaDiKB+Vc0Rc=";
|
||||||
|
};
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
|
runHook preInstall
|
||||||
|
|
||||||
|
yarn install
|
||||||
|
|
||||||
|
substituteInPlace node_modules/.bin/tsc \
|
||||||
|
--replace-fail '/usr/bin/env node' '${lib.getExe nodejs}'
|
||||||
|
|
||||||
|
substituteInPlace node_modules/.bin/webpack \
|
||||||
|
--replace-fail '/usr/bin/env node' '${lib.getExe nodejs}'
|
||||||
|
|
||||||
|
substituteInPlace node_modules/.bin/postject \
|
||||||
|
--replace-fail '/usr/bin/env node' '${lib.getExe nodejs}'
|
||||||
|
|
||||||
|
make VIV_VERSION=${finalAttrs.version} linux
|
||||||
|
|
||||||
|
mkdir -p $out/bin
|
||||||
|
install -Dm755 ./build/linux/viv $out/bin/viv
|
||||||
|
install -Dm755 ./build/linux/vivify-server $out/bin/vivify-server
|
||||||
|
|
||||||
|
wrapProgram $out/bin/viv \
|
||||||
|
--prefix PATH : ${
|
||||||
|
lib.makeBinPath [
|
||||||
|
nodejs
|
||||||
|
file
|
||||||
|
]
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
yarnConfigHook
|
||||||
|
npmHooks.npmInstallHook
|
||||||
|
zip
|
||||||
|
|
||||||
|
nodejs
|
||||||
|
file
|
||||||
|
];
|
||||||
|
|
||||||
|
# Stripping 'unneeded symbols' causes vivify-server executable to break
|
||||||
|
# (segmentation fault)
|
||||||
|
dontStrip = true;
|
||||||
|
|
||||||
|
passthru.updateScript = nix-update-script { };
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
description = "Live Markdown viewer";
|
||||||
|
longDescription = ''
|
||||||
|
Vivify brings your files to life in the browser!
|
||||||
|
Vivify is primarily made to render Markdown and Jupyter Notebooks, but will also
|
||||||
|
serve as a directory browser and let you view code files with syntax highlighting.
|
||||||
|
'';
|
||||||
|
homepage = "https://github.com/jannis-baum/Vivify";
|
||||||
|
changelog = "https://github.com/jannis-baum/Vivify/releases/tag/v${finalAttrs.src.tag}";
|
||||||
|
license = lib.licenses.gpl3;
|
||||||
|
maintainers = with lib.maintainers; [ skohtv ];
|
||||||
|
platforms = lib.platforms.linux;
|
||||||
|
mainProgram = "viv";
|
||||||
|
};
|
||||||
|
})
|
||||||
Reference in New Issue
Block a user