mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-03 20:33:21 +00:00
Merge master into staging-next
This commit is contained in:
commit
290f13d197
@ -642,41 +642,14 @@ in
|
||||
};
|
||||
|
||||
scriptArgs = "%i";
|
||||
path = [ pkgs.gawk cfgZfs.package ];
|
||||
path = [ cfgZfs.package ];
|
||||
|
||||
# ZFS has no way of enumerating just devices in a pool in a way
|
||||
# that 'zpool online -e' supports. Thus, we've implemented a
|
||||
# bit of a strange approach of highlighting just devices.
|
||||
# See: https://github.com/openzfs/zfs/issues/12505
|
||||
script = let
|
||||
# This UUID has been chosen at random and is to provide a
|
||||
# collision-proof, predictable token to search for
|
||||
magicIdentifier = "NIXOS-ZFS-ZPOOL-DEVICE-IDENTIFIER-37108bec-aff6-4b58-9e5e-53c7c9766f05";
|
||||
zpoolScripts = pkgs.writeShellScriptBin "device-highlighter" ''
|
||||
echo "${magicIdentifier}"
|
||||
'';
|
||||
in ''
|
||||
script = ''
|
||||
pool=$1
|
||||
|
||||
echo "Expanding all devices for $pool."
|
||||
|
||||
# Put our device-highlighter script it to the PATH
|
||||
export ZPOOL_SCRIPTS_PATH=${zpoolScripts}/bin
|
||||
|
||||
# Enable running our precisely specified zpool script as root
|
||||
export ZPOOL_SCRIPTS_AS_ROOT=1
|
||||
|
||||
devices() (
|
||||
zpool status -c device-highlighter "$pool" \
|
||||
| awk '($2 == "ONLINE" && $6 == "${magicIdentifier}") { print $1; }'
|
||||
)
|
||||
|
||||
for device in $(devices); do
|
||||
echo "Attempting to expand $device of $pool..."
|
||||
if ! zpool online -e "$pool" "$device"; then
|
||||
echo "Failed to expand '$device' of '$pool'."
|
||||
fi
|
||||
done
|
||||
${pkgs.zpool-auto-expand-partitions}/bin/zpool_part_disks --automatically-grow "$pool"
|
||||
'';
|
||||
};
|
||||
|
||||
@ -701,8 +674,6 @@ in
|
||||
RemainAfterExit = true;
|
||||
};
|
||||
|
||||
path = [ pkgs.gawk cfgZfs.package ];
|
||||
|
||||
script = ''
|
||||
for pool in ${poolListProvider}; do
|
||||
systemctl start --no-block "zpool-expand@$pool"
|
||||
|
@ -127,4 +127,54 @@ in {
|
||||
};
|
||||
|
||||
installer = (import ./installer.nix { }).zfsroot;
|
||||
|
||||
expand-partitions = makeTest {
|
||||
name = "multi-disk-zfs";
|
||||
nodes = {
|
||||
machine = { pkgs, ... }: {
|
||||
environment.systemPackages = [ pkgs.parted ];
|
||||
boot.supportedFilesystems = [ "zfs" ];
|
||||
networking.hostId = "00000000";
|
||||
|
||||
virtualisation = {
|
||||
emptyDiskImages = [ 20480 20480 20480 20480 20480 20480 ];
|
||||
};
|
||||
|
||||
specialisation.resize.configuration = {
|
||||
services.zfs.expandOnBoot = [ "tank" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
testScript = { nodes, ... }:
|
||||
''
|
||||
start_all()
|
||||
machine.wait_for_unit("default.target")
|
||||
print(machine.succeed('mount'))
|
||||
|
||||
print(machine.succeed('parted --script /dev/vdb -- mklabel gpt'))
|
||||
print(machine.succeed('parted --script /dev/vdb -- mkpart primary 1M 70M'))
|
||||
|
||||
print(machine.succeed('parted --script /dev/vdc -- mklabel gpt'))
|
||||
print(machine.succeed('parted --script /dev/vdc -- mkpart primary 1M 70M'))
|
||||
|
||||
print(machine.succeed('zpool create tank mirror /dev/vdb1 /dev/vdc1 mirror /dev/vdd /dev/vde mirror /dev/vdf /dev/vdg'))
|
||||
print(machine.succeed('zpool list -v'))
|
||||
print(machine.succeed('mount'))
|
||||
start_size = int(machine.succeed('df -k --output=size /tank | tail -n1').strip())
|
||||
|
||||
print(machine.succeed("/run/current-system/specialisation/resize/bin/switch-to-configuration test >&2"))
|
||||
machine.wait_for_unit("zpool-expand-pools.service")
|
||||
machine.wait_for_unit("zpool-expand@tank.service")
|
||||
|
||||
print(machine.succeed('zpool list -v'))
|
||||
new_size = int(machine.succeed('df -k --output=size /tank | tail -n1').strip())
|
||||
|
||||
if (new_size - start_size) > 20000000:
|
||||
print("Disk grew appropriately.")
|
||||
else:
|
||||
print(f"Disk went from {start_size} to {new_size}, which doesn't seem right.")
|
||||
exit(1)
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
@ -38,13 +38,13 @@ let
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "cudatext";
|
||||
version = "1.159.2";
|
||||
version = "1.160.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Alexey-T";
|
||||
repo = "CudaText";
|
||||
rev = version;
|
||||
sha256 = "sha256-dSZd+Dsln7xUfN/cqTZSdnpnINHsDCBrbNGcDLwqzzU=";
|
||||
sha256 = "sha256-42V6RFa+mAXyaUuKeDQa9Voi1MjnzcVl+cOA65VabxM=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
|
@ -16,8 +16,8 @@
|
||||
},
|
||||
"ATSynEdit": {
|
||||
"owner": "Alexey-T",
|
||||
"rev": "2022.03.23",
|
||||
"sha256": "sha256-D/pQ4TSWUaL97Nau3bGi7rc8MxnvuoDcD7HDNEDwmsk="
|
||||
"rev": "2022.04.06",
|
||||
"sha256": "sha256-EnPOAl1qsdcYzmUgT5rSYqY/xOLSfDcMNCXIG8LC4H0="
|
||||
},
|
||||
"ATSynEdit_Cmp": {
|
||||
"owner": "Alexey-T",
|
||||
|
@ -21,7 +21,12 @@ stdenv.mkDerivation rec {
|
||||
openssl
|
||||
];
|
||||
|
||||
makeFlags = [ "DESTDIR=$(out)" "bindir=/bin" ];
|
||||
makeFlags = [
|
||||
"CC:=$(CC)"
|
||||
"STRIP:=$(STRIP)"
|
||||
"DESTDIR=$(out)"
|
||||
"bindir=/bin"
|
||||
];
|
||||
|
||||
preInstall = ''
|
||||
mkdir -p "$out/bin"
|
||||
|
77
pkgs/applications/misc/bikeshed/default.nix
Normal file
77
pkgs/applications/misc/bikeshed/default.nix
Normal file
@ -0,0 +1,77 @@
|
||||
{ lib
|
||||
, buildPythonApplication
|
||||
, fetchPypi
|
||||
# build inputs
|
||||
, aiofiles
|
||||
, aiohttp
|
||||
, attrs
|
||||
, certifi
|
||||
, cssselect
|
||||
, html5lib
|
||||
, isodate
|
||||
, json-home-client
|
||||
, lxml
|
||||
, pillow
|
||||
, pygments
|
||||
, requests
|
||||
, result
|
||||
, setuptools
|
||||
, tenacity
|
||||
, widlparser
|
||||
}:
|
||||
|
||||
buildPythonApplication rec {
|
||||
pname = "bikeshed";
|
||||
version = "3.4.3";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "sha256-vJW4yNbKCZraJ5vx8FheNsBl+zObGoLFgAVqoU0p9QQ=";
|
||||
};
|
||||
|
||||
# Relax requirements from "==" to ">="
|
||||
# https://github.com/tabatkins/bikeshed/issues/2178
|
||||
postPatch = ''
|
||||
substituteInPlace requirements.txt \
|
||||
--replace "==" ">="
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
aiofiles
|
||||
aiohttp
|
||||
attrs
|
||||
certifi
|
||||
cssselect
|
||||
html5lib
|
||||
isodate
|
||||
json-home-client
|
||||
lxml
|
||||
pillow
|
||||
pygments
|
||||
requests
|
||||
result
|
||||
setuptools
|
||||
tenacity
|
||||
widlparser
|
||||
];
|
||||
|
||||
checkPhase = ''
|
||||
$out/bin/bikeshed test
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [ "bikeshed" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Preprocessor for anyone writing specifications that converts source files into actual specs";
|
||||
longDescription = ''
|
||||
Bikeshed is a pre-processor for spec documents, turning a source document
|
||||
(containing only the actual spec content, plus several shorthands for linking
|
||||
to terms and other things) into a final spec document, with appropriate boilerplate,
|
||||
bibliography, indexes, etc all filled in. It's used on specs for CSS
|
||||
and many other W3C working groups, WHATWG, the C++ standards committee, and elsewhere!
|
||||
'';
|
||||
homepage = "https://tabatkins.github.io/bikeshed/";
|
||||
license = licenses.cc0;
|
||||
maintainers = [ maintainers.kvark ];
|
||||
};
|
||||
}
|
@ -2,11 +2,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gpsprune";
|
||||
version = "21.1";
|
||||
version = "21.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://activityworkshop.net/software/gpsprune/gpsprune_${version}.jar";
|
||||
sha256 = "sha256-WyI9IKzUmKGiqiYs6SSuGhVUdO2UCsPSSL/IjPLykiM=";
|
||||
sha256 = "sha256-QgbLbpqlC2sITbPK4ZcaovmycwhWtnu06x8F0grpECc=";
|
||||
};
|
||||
|
||||
dontUnpack = true;
|
||||
|
@ -19,13 +19,13 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "lagrange";
|
||||
version = "1.12.0";
|
||||
version = "1.12.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "skyjake";
|
||||
repo = "lagrange";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-1eWd4En14p8E04kLWbsbJSEdjManQ87N/P3klFbUQx4=";
|
||||
sha256 = "sha256-CpvoovTn++RTQjyeOlHTG+cjn32F+9qP32+YHpoLB8M=";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
|
@ -66,6 +66,7 @@ let
|
||||
timstott
|
||||
zimbatm
|
||||
zowoq
|
||||
techknowlogick
|
||||
];
|
||||
};
|
||||
} // attrs');
|
||||
@ -191,9 +192,9 @@ rec {
|
||||
};
|
||||
|
||||
terraform_1 = mkTerraform {
|
||||
version = "1.1.7";
|
||||
sha256 = "sha256-E8qY17MSdA7fQW4wGSDiPzbndBP5SZwelAJAWzka/io=";
|
||||
vendorSha256 = "sha256-lyy/hcr00ix6qZoxzSfCbXvDC8dRB2ZjrONywpqbVZ8=";
|
||||
version = "1.1.8";
|
||||
sha256 = "sha256-U3RuLnDQD1EbPZG/wPuVMbSKmR3EqspkoK0Ky8aZb7k=";
|
||||
vendorSha256 = "sha256-Jy9o0O80OjagrHG25CSPblI49zKx0N8pwvEotk9qm3s=";
|
||||
patches = [ ./provider-path-0_15.patch ];
|
||||
passthru = { inherit plugins; };
|
||||
};
|
||||
|
@ -8,18 +8,18 @@
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "shellhub-agent";
|
||||
version = "0.9.0";
|
||||
version = "0.9.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "shellhub-io";
|
||||
repo = "shellhub";
|
||||
rev = "v${version}";
|
||||
sha256 = "A1634b3uxlILMpx/9jpCIApqAqofvD4ZPasVKL29Gtc=";
|
||||
sha256 = "E1TX3GBVKn0tXloNhyiXOtDwSlO7mwXJ6zaOSHKZEFc=";
|
||||
};
|
||||
|
||||
modRoot = "./agent";
|
||||
|
||||
vendorSha256 = "sha256-LxJtLQr8djoRGznT5hL2agTgtZY6pFS8Zo0BwHDmugc=";
|
||||
vendorSha256 = "sha256-sPb49tRUHhwow7+IKiN33sgWYAa3lTpOD1vh8e5Wy68=";
|
||||
|
||||
ldflags = [ "-s" "-w" "-X main.AgentVersion=v${version}" ];
|
||||
|
||||
|
@ -151,6 +151,7 @@ writeTextFile rec {
|
||||
|
||||
# needed for cython
|
||||
export CC='${stdenv.cc}/bin/${stdenv.cc.targetPrefix}cc'
|
||||
export CXX='${stdenv.cc}/bin/${stdenv.cc.targetPrefix}c++'
|
||||
# cython needs to find these libraries, otherwise will fail with `ld: cannot find -lflint` or similar
|
||||
export LDFLAGS='${
|
||||
lib.concatStringsSep " " (map (pkg: "-L${pkg}/lib") [
|
||||
@ -178,6 +179,7 @@ writeTextFile rec {
|
||||
mpfr.dev
|
||||
])
|
||||
}'
|
||||
export CXXFLAGS=$CFLAGS
|
||||
|
||||
export SAGE_LIB='${sagelib}/${python3.sitePackages}'
|
||||
|
||||
|
@ -121,10 +121,10 @@ stdenv.mkDerivation rec {
|
||||
|
||||
# https://trac.sagemath.org/ticket/33170
|
||||
(fetchSageDiff {
|
||||
base = "9.5.rc1";
|
||||
name = "ipython-8-update.patch";
|
||||
rev = "a90a314616d86d6be9c0d5233f0d36c4bfe06231";
|
||||
sha256 = "sha256-pXdtokTo84xNCnV+HyAKEzG562z8FjzJ7hczOja0dRw=";
|
||||
base = "9.6.beta5";
|
||||
name = "ipython-8.1-update.patch";
|
||||
rev = "4d2b53f1541375861310af3a7f7109c1c2ed475d";
|
||||
sha256 = "sha256-ELda/VBzsQH7NdFas69fQ35QPUoJCeLx/gxT1j7qGR8=";
|
||||
})
|
||||
|
||||
# https://trac.sagemath.org/ticket/32968
|
||||
@ -156,6 +156,22 @@ stdenv.mkDerivation rec {
|
||||
|
||||
# adapted from https://trac.sagemath.org/ticket/23712#comment:22
|
||||
./patches/tachyon-renamed-focallength.patch
|
||||
|
||||
# https://trac.sagemath.org/ticket/33336
|
||||
(fetchSageDiff {
|
||||
base = "9.6.beta2";
|
||||
name = "scipy-1.8-update.patch";
|
||||
rev = "9c8235e44ffb509efa8a3ca6cdb55154e2b5066d";
|
||||
sha256 = "sha256-bfc4ljNOxVnhlmxIuNbjbKl4vJXYq2tlF3Z8bbC8PWw=";
|
||||
})
|
||||
|
||||
# https://trac.sagemath.org/ticket/33495
|
||||
(fetchSageDiff {
|
||||
base = "9.6.beta5";
|
||||
name = "networkx-2.7-update.patch";
|
||||
rev = "8452003846a7303100847d8d0ed642fc642c11d6";
|
||||
sha256 = "sha256-A/XMouPlc2sjFp30L+56fBGJXydS2EtzfPOV98FCDqI=";
|
||||
})
|
||||
];
|
||||
|
||||
patches = nixPatches ++ bugfixPatches ++ packageUpgradePatches;
|
||||
|
@ -181,11 +181,16 @@ buildPythonPackage rec {
|
||||
# some files, like Pipfile, pyproject.toml, requirements.txt and setup.cfg
|
||||
# are generated by the bootstrap script using m4. these can fetch data from
|
||||
# build/pkgs, either directly or via sage-get-system-packages.
|
||||
sed -i 's/==2.1.0rc1/>=2.1.1/' ../gmpy2/install-requires.txt
|
||||
sed -i 's/, <3.4//' ../rpy2/install-requires.txt
|
||||
sed -i 's/, <4.3//' ../sphinx/install-requires.txt
|
||||
sed -i '/sage_conf/d' src/setup.cfg.m4
|
||||
sed -i '/sage_conf/d' src/requirements.txt.m4
|
||||
|
||||
# version lower bounds are useful, but upper bounds are a hassle because
|
||||
# Sage tests already catch any relevant API breakage.
|
||||
# according to the discussion at https://trac.sagemath.org/ticket/33520,
|
||||
# upper bounds will be less noisy starting from Sage 9.6.
|
||||
sed -i 's/==2.1.0rc1/>=2.1.1/' ../gmpy2/install-requires.txt
|
||||
sed -i 's/, <[^, ]*//' ../*/install-requires.txt
|
||||
|
||||
for infile in src/*.m4; do
|
||||
if [ -f "$infile" ]; then
|
||||
outfile="src/$(basename $infile .m4)"
|
||||
|
@ -2,13 +2,13 @@
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "docker-buildx";
|
||||
version = "0.8.1";
|
||||
version = "0.8.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "docker";
|
||||
repo = "buildx";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-NJNFjzbiBcmXcBF1k0qybv5LnkaQ+1ehSfF18CC85JY=";
|
||||
sha256 = "sha256-AGRdmYKd76k5tmBTTqsSHj3yOU8QSd11G5ito0O/dWY=";
|
||||
};
|
||||
|
||||
vendorSha256 = null;
|
||||
|
@ -30,8 +30,9 @@ stdenv.mkDerivation rec {
|
||||
'';
|
||||
|
||||
cmakeFlags = [
|
||||
"-DCIVETWEB_ENABLE_CXX=ON"
|
||||
"-DBUILD_SHARED_LIBS=ON"
|
||||
"-DCIVETWEB_ENABLE_CXX=ON"
|
||||
"-DCIVETWEB_ENABLE_IPV6=ON"
|
||||
|
||||
# The civetweb unit tests rely on downloading their fork of libcheck.
|
||||
"-DCIVETWEB_BUILD_TESTING=OFF"
|
||||
|
@ -1,35 +1,27 @@
|
||||
{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, result }:
|
||||
|
||||
let
|
||||
pname = "cmdliner";
|
||||
in
|
||||
|
||||
assert lib.versionAtLeast ocaml.version "4.01.0";
|
||||
|
||||
let param =
|
||||
if lib.versionAtLeast ocaml.version "4.03" then {
|
||||
version = "1.0.4";
|
||||
sha256 = "1h04q0zkasd0mw64ggh4y58lgzkhg6yhzy60lab8k8zq9ba96ajw";
|
||||
} else {
|
||||
version = "1.0.2";
|
||||
sha256 = "18jqphjiifljlh9jg8zpl6310p3iwyaqphdkmf89acyaix0s4kj1";
|
||||
}
|
||||
; in
|
||||
assert (lib.versionAtLeast ocaml.version "4.03");
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "ocaml${ocaml.version}-${pname}-${version}";
|
||||
inherit (param) version;
|
||||
pname = "cmdliner";
|
||||
version = "1.0.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://erratique.ch/software/${pname}/releases/${pname}-${version}.tbz";
|
||||
inherit (param) sha256;
|
||||
sha256 = "1h04q0zkasd0mw64ggh4y58lgzkhg6yhzy60lab8k8zq9ba96ajw";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ ocaml ocamlbuild findlib topkg ];
|
||||
buildInputs = [ topkg ];
|
||||
propagatedBuildInputs = [ result ];
|
||||
nativeBuildInputs = [ ocaml ];
|
||||
|
||||
inherit (topkg) buildPhase installPhase;
|
||||
makeFlags = [ "PREFIX=$(out)" ];
|
||||
installTargets = "install install-doc";
|
||||
installFlags = [
|
||||
"LIBDIR=$(out)/lib/ocaml/${ocaml.version}/site-lib/${pname}"
|
||||
"DOCDIR=$(out)/share/doc/${pname}"
|
||||
];
|
||||
postInstall = ''
|
||||
mv $out/lib/ocaml/${ocaml.version}/site-lib/${pname}/{opam,${pname}.opam}
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://erratique.ch/software/cmdliner";
|
||||
|
40
pkgs/development/python-modules/json-home-client/default.nix
Normal file
40
pkgs/development/python-modules/json-home-client/default.nix
Normal file
@ -0,0 +1,40 @@
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pythonOlder
|
||||
# build inputs
|
||||
, typing-extensions
|
||||
, uri-template
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "json-home-client";
|
||||
version = "1.1.1";
|
||||
|
||||
disabled = pythonOlder "3.6";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "plinss";
|
||||
repo = "json_home_client";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-DhnvvY1nMe1sdRE+OgjBt4TsLmiqnD8If4rl700zW9E=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e 's/0.0.0/${version}/' setup.py
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
typing-extensions
|
||||
uri-template
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "json_home_client" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Client class for calling http+json APIs in Python";
|
||||
homepage = "https://github.com/plinss/json_home_client";
|
||||
license = licenses.mit;
|
||||
maintainers = [ maintainers.kvark ];
|
||||
};
|
||||
}
|
@ -11,7 +11,7 @@
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pre-commit-hooks";
|
||||
version = "4.1.0";
|
||||
version = "4.2.0";
|
||||
format = "setuptools";
|
||||
|
||||
disabled = pythonOlder "3.6";
|
||||
@ -19,8 +19,8 @@ buildPythonPackage rec {
|
||||
src = fetchFromGitHub {
|
||||
owner = "pre-commit";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-nxJp7LkCUkJj77RCeWedBusue3x0lZYatSidbueZqfo=";
|
||||
rev = "refs/tags/v${version}";
|
||||
sha256 = "sha256-jSu4LutEgpeAbCgSHgk6VXQKLZo00T3TrQVZxsNU1co=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
|
45
pkgs/development/python-modules/result/default.nix
Normal file
45
pkgs/development/python-modules/result/default.nix
Normal file
@ -0,0 +1,45 @@
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pytestCheckHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "result";
|
||||
version = "0.7.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "rustedpy";
|
||||
repo = "result";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-bEf3OJg6ksDvzZE7ezA58Q2FObb5V7BG8vkKtX284Jg=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace pyproject.toml \
|
||||
--replace '"--flake8",' "" \
|
||||
--replace '"--tb=short",' "" \
|
||||
--replace '"--cov=result",' "" \
|
||||
--replace '"--cov=tests",' "" \
|
||||
--replace '"--cov-report=term",' "" \
|
||||
--replace '"--cov-report=xml",' ""
|
||||
'';
|
||||
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
disabledTestPaths = [
|
||||
#TODO: figure out the failure "match o:" Invalid Syntax
|
||||
"tests/test_pattern_matching.py"
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "result" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A simple Result type for Python 3 inspired by Rust, fully type annotated";
|
||||
homepage = "https://github.com/rustedpy/result";
|
||||
license = licenses.mit;
|
||||
maintainers = [ maintainers.kvark ];
|
||||
};
|
||||
}
|
30
pkgs/development/python-modules/uri-template/default.nix
Normal file
30
pkgs/development/python-modules/uri-template/default.nix
Normal file
@ -0,0 +1,30 @@
|
||||
{ lib, buildPythonPackage, fetchFromGitHub, python }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "uri-template";
|
||||
version = "1.2.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "plinss";
|
||||
repo = "uri_template";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-IAq6GpEwimq45FU0QugLZLSOhwAmC1KbpZKD0zyxsUs=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e 's/0.0.0/${version}/' setup.py
|
||||
'';
|
||||
|
||||
checkPhase = ''
|
||||
${python.interpreter} test.py
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [ "uri_template" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "An implementation of RFC 6570 URI Templates";
|
||||
homepage = "https://github.com/plinss/uri_template/";
|
||||
license = licenses.mit;
|
||||
maintainers = [ maintainers.kvark ];
|
||||
};
|
||||
}
|
38
pkgs/development/python-modules/widlparser/default.nix
Normal file
38
pkgs/development/python-modules/widlparser/default.nix
Normal file
@ -0,0 +1,38 @@
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pythonOlder
|
||||
# build inputs
|
||||
, typing-extensions
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "widlparser";
|
||||
version = "1.0.12";
|
||||
|
||||
disabled = pythonOlder "3.7";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "plinss";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-T17fDWYd1naza/ao7kXWGcRIl2fzL1/Z9SaJiutZzqk=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e 's/0.0.0/${version}/' setup.py
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
typing-extensions
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "widlparser" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Stand-alone WebIDL Parser in Python";
|
||||
homepage = "https://github.com/plinss/widlparser";
|
||||
license = licenses.mit;
|
||||
maintainers = [ maintainers.kvark ];
|
||||
};
|
||||
}
|
@ -2,14 +2,14 @@
|
||||
|
||||
nimPackages.buildNimPackage rec {
|
||||
pname = "nitter";
|
||||
version = "unstable-2022-02-11";
|
||||
version = "unstable-2022-03-21";
|
||||
nimBinOnly = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "zedeus";
|
||||
repo = "nitter";
|
||||
rev = "6695784050605c77a301c0a66764fa9a9580a2f5";
|
||||
sha256 = "1lddzf6m74bw5kkv465cp211xxqbwnfacav7ia3y9i38rrnqwk6m";
|
||||
rev = "6884f05041a9b8619ec709afacdfdd6482a120a0";
|
||||
sha256 = "1mnc6jqljpqp9lgcrxxvf3aiswssr34v139cxfbwlmj45swmsazh";
|
||||
};
|
||||
|
||||
buildInputs = with nimPackages; [
|
||||
|
40
pkgs/servers/nitter/update.sh
Executable file
40
pkgs/servers/nitter/update.sh
Executable file
@ -0,0 +1,40 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p common-updater-scripts curl jq nix nix-prefetch-git patchutils
|
||||
set -euo pipefail
|
||||
|
||||
info() {
|
||||
if [ -t 2 ]; then
|
||||
set -- '\033[32m%s\033[39m\n' "$@"
|
||||
else
|
||||
set -- '%s\n' "$@"
|
||||
fi
|
||||
printf "$@" >&2
|
||||
}
|
||||
|
||||
nitter_old_version=$(nix-instantiate --eval --strict --json -A nitter.version . | jq -r .)
|
||||
nitter_old_rev=$(nix-instantiate --eval --strict --json -A nitter.src.rev . | jq -r .)
|
||||
today=$(LANG=C date -u +'%Y-%m-%d')
|
||||
|
||||
# use latest commit before today, we should not call the version *today*
|
||||
# because there might still be commits coming
|
||||
# use the day of the latest commit we picked as version
|
||||
commit=$(curl -Sfs "https://api.github.com/repos/zedeus/nitter/compare/$nitter_old_rev~1...master" \
|
||||
| jq '.commits | map(select(.commit.committer.date < $today) | {sha, date: .commit.committer.date}) | .[-1]' --arg today "$today")
|
||||
nitter_new_rev=$(jq -r '.sha' <<< "$commit")
|
||||
nitter_new_version="unstable-$(jq -r '.date[0:10]' <<< "$commit")"
|
||||
info "latest commit before $today: $nitter_new_rev ($(jq -r '.date' <<< "$commit"))"
|
||||
|
||||
if [ "$nitter_new_rev" = "$nitter_old_rev" ]; then
|
||||
info "nitter is up-to-date."
|
||||
exit
|
||||
fi
|
||||
|
||||
if curl -Sfs "https://github.com/zedeus/nitter/compare/$nitter_old_rev...$nitter_new_rev.patch" \
|
||||
| lsdiff | grep -Fxe 'a/nitter.nimble' -e 'b/nitter.nimble' > /dev/null; then
|
||||
info "nitter.nimble changed, some dependencies probably need updating."
|
||||
fi
|
||||
|
||||
nitter_new_sha256=$(nix-prefetch-git --rev "$nitter_new_rev" "https://github.com/zedeus/nitter.git" | jq -r .sha256)
|
||||
update-source-version nitter "$nitter_new_version" "$nitter_new_sha256" --rev="$nitter_new_rev"
|
||||
git commit --all --verbose --message "nitter: $nitter_old_version -> $nitter_new_version"
|
||||
info "Updated nitter to $nitter_new_version."
|
@ -0,0 +1,46 @@
|
||||
{ rustPlatform
|
||||
, cloud-utils
|
||||
, fetchFromGitHub
|
||||
, lib
|
||||
, llvmPackages
|
||||
, pkg-config
|
||||
, util-linux
|
||||
, zfs
|
||||
}:
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "zpool-auto-expand-partitions";
|
||||
version = "0.1.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "DeterminateSystems";
|
||||
repo = "zpool-auto-expand-partitions";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-LA6YO6vv7VCXwFfayQVxVR80niSCo89sG0hqh0wDEh8=";
|
||||
};
|
||||
|
||||
cargoHash = "sha256-5v0fqp8aro+QD/f5VudMREc8RvKQapNAoArcCKMN1Sw=";
|
||||
|
||||
preBuild = ''
|
||||
substituteInPlace src/grow.rs \
|
||||
--replace '"growpart"' '"${cloud-utils}/bin/growpart"'
|
||||
substituteInPlace src/lsblk.rs \
|
||||
--replace '"lsblk"' '"${util-linux}/bin/lsblk"'
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
rustPlatform.bindgenHook
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
util-linux
|
||||
zfs
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A tool that aims to expand all partitions in a specified zpool to fill the available space";
|
||||
homepage = "https://github.com/DeterminateSystems/zpool-auto-expand-partitions";
|
||||
license = licenses.asl20;
|
||||
maintainers = teams.determinatesystems.members;
|
||||
};
|
||||
}
|
@ -10,16 +10,16 @@
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "findomain";
|
||||
version = "7.2.0";
|
||||
version = "8.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Edu4rdSHL";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
sha256 = "sha256-NhsEXYEYoRZ/HlMS+MP/N+ZxB13DDZr5B8MY5dbONP0=";
|
||||
sha256 = "sha256-Bk3p8+FkjrF/nLsPRx8daqieV8iewAbcoO2DglFSERg=";
|
||||
};
|
||||
|
||||
cargoSha256 = "sha256-Y/DgAMWhTgHuhdbYxpsg7UxLF7hXNQEY1aoaUbKdDEM=";
|
||||
cargoSha256 = "sha256-chHr/3yN2PLUQLYqkln12q3+n7tX2IclVGpXBCkPxCQ=";
|
||||
|
||||
nativeBuildInputs = [ installShellFiles perl ];
|
||||
buildInputs = lib.optionals stdenv.isDarwin [ libiconv Security ];
|
||||
|
@ -13,8 +13,6 @@ buildGoModule rec {
|
||||
|
||||
vendorSha256 = "sha256-guJgLjmB29sOLIzs2+gKNp0WTWC3zS9Sb5DD5IistKY=";
|
||||
|
||||
doCheck = false;
|
||||
|
||||
ldflags = [ "-s" "-w" "-X main.version=${version}" ];
|
||||
|
||||
meta = with lib; {
|
||||
|
@ -1071,6 +1071,8 @@ with pkgs;
|
||||
|
||||
cf-vault = callPackage ../tools/admin/cf-vault { };
|
||||
|
||||
bikeshed = python3Packages.callPackage ../applications/misc/bikeshed { };
|
||||
|
||||
cope = callPackage ../tools/misc/cope { };
|
||||
|
||||
ejson2env = callPackage ../tools/admin/ejson2env { };
|
||||
@ -11619,6 +11621,8 @@ with pkgs;
|
||||
|
||||
zfsnap = callPackage ../tools/backup/zfsnap { };
|
||||
|
||||
zpool-auto-expand-partitions = callPackage ../tools/filesystems/zpool-auto-expand-partitions { };
|
||||
|
||||
zile = callPackage ../applications/editors/zile { };
|
||||
|
||||
zinnia = callPackage ../tools/inputmethods/zinnia { };
|
||||
|
@ -4335,6 +4335,8 @@ in {
|
||||
|
||||
jsonmerge = callPackage ../development/python-modules/jsonmerge { };
|
||||
|
||||
json-home-client = callPackage ../development/python-modules/json-home-client { };
|
||||
|
||||
json-merge-patch = callPackage ../development/python-modules/json-merge-patch { };
|
||||
|
||||
json-schema-for-humans = callPackage ../development/python-modules/json-schema-for-humans { };
|
||||
@ -8821,6 +8823,8 @@ in {
|
||||
|
||||
restview = callPackage ../development/python-modules/restview { };
|
||||
|
||||
result = callPackage ../development/python-modules/result { };
|
||||
|
||||
rethinkdb = callPackage ../development/python-modules/rethinkdb { };
|
||||
|
||||
retry = callPackage ../development/python-modules/retry { };
|
||||
@ -10459,6 +10463,8 @@ in {
|
||||
|
||||
uritemplate = callPackage ../development/python-modules/uritemplate { };
|
||||
|
||||
uri-template = callPackage ../development/python-modules/uri-template { };
|
||||
|
||||
uritools = callPackage ../development/python-modules/uritools { };
|
||||
|
||||
url-normalize = callPackage ../development/python-modules/url-normalize { };
|
||||
@ -10749,6 +10755,8 @@ in {
|
||||
|
||||
widgetsnbextension = callPackage ../development/python-modules/widgetsnbextension { };
|
||||
|
||||
widlparser = callPackage ../development/python-modules/widlparser { };
|
||||
|
||||
wiffi = callPackage ../development/python-modules/wiffi { };
|
||||
|
||||
willow = callPackage ../development/python-modules/willow { };
|
||||
|
Loading…
Reference in New Issue
Block a user