Add kana independent search with tamerye extension

This commit is contained in:
2026-06-04 02:00:00 +09:00
parent ce45ae7cc8
commit e93cd0df4b
7 changed files with 124 additions and 15 deletions
+22 -6
View File
@@ -4,6 +4,11 @@
inputs = {
nixpkgs.url = "nixpkgs/nixos-unstable";
tamerye = {
url = "git+https://git.pvv.ntnu.no/Mugiten/tamerye.git?ref=main";
inputs.nixpkgs.follows = "nixpkgs";
};
datasources = {
url = "git+https://git.pvv.ntnu.no/Mugiten/datasources.git";
inputs.nixpkgs.follows = "nixpkgs";
@@ -13,6 +18,7 @@
outputs = {
self,
nixpkgs,
tamerye,
datasources,
}: let
inherit (nixpkgs) lib;
@@ -24,7 +30,14 @@
"armv7l-linux"
];
forAllSystems = f: lib.genAttrs systems (system: f system nixpkgs.legacyPackages.${system});
forAllSystems = f: lib.genAttrs systems (system: let
pkgs = import nixpkgs {
inherit system;
overlays = [
tamerye.overlays.default
];
};
in f system pkgs);
in {
apps = forAllSystems (system: pkgs: {
default = {
@@ -35,7 +48,7 @@
runtimeEnv = {
JADB_PATH = "${self.packages.${system}.database}/jadb.sqlite";
LIBSQLITE_PATH = "${pkgs.sqlite.out}/lib/libsqlite3.so";
LIBSQLITE_PATH = "${pkgs.tamerye-sqlite}/lib/libsqlite3.so";
};
text = ''
@@ -63,18 +76,18 @@
gnumake
lcov
sqldiff
sqlite-interactive
tamerye-sqlite-cli
];
env = {
LIBSQLITE_PATH = "${pkgs.sqlite.out}/lib/libsqlite3.so";
LIBSQLITE_PATH = "${pkgs.tamerye-sqlite}/lib/libsqlite3.so";
JADB_PATH = "result/jadb.sqlite";
LD_LIBRARY_PATH = lib.makeLibraryPath [ pkgs.sqlite ];
LD_LIBRARY_PATH = lib.makeLibraryPath [ pkgs.tamerye-sqlite ];
};
};
sqlite-debugging = pkgs.mkShell {
packages = with pkgs; [
sqlite-interactive
tamerye-sqlite-cli
sqlite-analyzer
sqlite-web
# sqlint
@@ -119,16 +132,19 @@
inherit (datasources.packages.${system}) jmdict radkfile kanjidic2;
database-tool = pkgs.callPackage ./nix/database_tool.nix {
sqlite = pkgs.tamerye-sqlite;
inherit src;
};
database = pkgs.callPackage ./nix/database.nix {
sqlite = pkgs.tamerye-sqlite-cli;
inherit (datasources.packages.${system}) jmdict radkfile kanjidic2 tanos-jlpt;
inherit (self.packages.${system}) database-tool;
inherit src;
};
database-wal = pkgs.callPackage ./nix/database.nix {
sqlite = pkgs.tamerye-sqlite-cli;
inherit (datasources.packages.${system}) jmdict radkfile kanjidic2 tanos-jlpt;
inherit (self.packages.${system}) database-tool;
inherit src;