websurfx: init at 1.20.7
This commit is contained in:
parent
616735586a
commit
a5865295af
60
pkgs/by-name/we/websurfx/package.nix
Normal file
60
pkgs/by-name/we/websurfx/package.nix
Normal file
@ -0,0 +1,60 @@
|
||||
{
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
rustPlatform,
|
||||
openssl,
|
||||
pkg-config,
|
||||
}:
|
||||
let
|
||||
version = "1.20.7";
|
||||
in
|
||||
rustPlatform.buildRustPackage {
|
||||
pname = "websurfx";
|
||||
inherit version;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "neon-mmd";
|
||||
repo = "websurfx";
|
||||
rev = "refs/tags/v${version}";
|
||||
hash = "sha256-fpyelpzskwuVrQB1SZ3llnenox7MiOeF+sSJONSdEf0=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
openssl
|
||||
];
|
||||
|
||||
useFetchCargoVendor = true;
|
||||
|
||||
cargoHash = "sha256-LnMVfsKb1oTsEKmD/dDnABbWyrYC52e9ASbcMY7qXMw=";
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace src/handler/mod.rs \
|
||||
--replace-fail "/etc/xdg" "$out/etc/xdg" \
|
||||
--replace-fail "/opt/websurfx" "$out/opt/websurfx"
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/etc/xdg
|
||||
mkdir -p $out/opt/websurfx
|
||||
|
||||
cp -r websurfx $out/etc/xdg/
|
||||
cp -r public $out/opt/websurfx/
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Open source alternative to searx";
|
||||
longDescription = ''
|
||||
An open source alternative to searx which provides a modern-looking,
|
||||
lightning-fast, privacy respecting, secure meta search engine.
|
||||
'';
|
||||
homepage = "https://github.com/neon-mmd/websurfx";
|
||||
changelog = "https://github.com/neon-mmd/websurfx/releases";
|
||||
license = lib.licenses.agpl3Plus;
|
||||
maintainers = with lib.maintainers; [ theobori ];
|
||||
mainProgram = "websurfx";
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user