10 version = "0-unstable-2024-08-29";
12 src = fetchFromGitHub {
15 rev = "1fcd7787886503f703bbcd31b193d4c93acc5610";
16 hash = "sha256-o/n8rgngQkYEn8J0aFpCiD4qrWVFaaa305OxiscU6+8=";
17 fetchSubmodules = true;
20 vendorHash = "sha256-dsS5w8JXIwkneWScOFzLSDiXq+clgK+RdYiMw0+FnvY=";
22 patches = [ ./0001-fix-minimal-go-version.patch ];
24 nativeBuildInputs = [ makeWrapper ];
32 # For the default config to work, we have to put `static/data` and
33 # `db.sqlite3` in a temporary directory since they need to be writeable.
35 # NOTE: Currently, `static/data` only holds the snapshots directory.
36 substituteInPlace config.yml \
37 --replace-fail 'root: "./static/data"' 'root: "/tmp/omnom/static/data"' \
38 --replace-fail 'connection: "./db.sqlite3"' 'connection: "/tmp/omnom/db.sqlite3"' \
39 --replace-fail 'debug: true' 'debug: false'
44 cp -r config.yml static templates $out/share
46 wrapProgram $out/bin/omnom \
48 --set-default GIN_MODE release
52 description = "A webpage bookmarking and snapshotting service";
53 homepage = "https://github.com/asciimoo/omnom";
54 license = lib.licenses.agpl3Only;
55 maintainers = lib.teams.ngi.members;
56 mainProgram = "omnom";