Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Kubo testing #241931

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion lib/modules.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ let
filter
foldl'
getAttrFromPath
hasAttrByPath
head
id
imap1
Expand Down Expand Up @@ -1203,6 +1204,7 @@ let
doRename = { from, to, visible, warn, use, withPriority ? true }:
{ config, options, ... }:
let
fromOptIsDefined = hasAttrByPath from options;
fromOpt = getAttrFromPath from options;
toOf = attrByPath to
(abort "Renaming error: option `${showOption to}' does not exist.");
Expand All @@ -1218,7 +1220,7 @@ let
});
config = mkMerge [
(optionalAttrs (options ? warnings) {
warnings = optional (warn && fromOpt.isDefined)
warnings = optional (warn && fromOptIsDefined && fromOpt.isDefined)
"The option `${showOption from}' defined in ${showFiles fromOpt.files} has been renamed to `${showOption to}'.";
})
(if withPriority
Expand Down
1 change: 1 addition & 0 deletions nixos/modules/services/network-filesystems/kubo.nix
Original file line number Diff line number Diff line change
Expand Up @@ -420,5 +420,6 @@ in
(mkRenamedOptionModule [ "services" "kubo" "gatewayAddress" ] [ "services" "kubo" "settings" "Addresses" "Gateway" ])
(mkRenamedOptionModule [ "services" "kubo" "apiAddress" ] [ "services" "kubo" "settings" "Addresses" "API" ])
(mkRenamedOptionModule [ "services" "kubo" "swarmAddress" ] [ "services" "kubo" "settings" "Addresses" "Swarm" ])
(mkRenamedOptionModule [ "services" "kubo" "settings" "Experimental" "AcceleratedDHTClient" ] [ "services" "kubo" "settings" "Routing" "AcceleratedDHTClient" ])
];
}
6 changes: 3 additions & 3 deletions pkgs/applications/networking/kubo/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@

buildGoModule rec {
pname = "kubo";
version = "0.20.0"; # When updating, also check if the repo version changed and adjust repoVersion below
version = "0.21.0"; # When updating, also check if the repo version changed and adjust repoVersion below
rev = "v${version}";

passthru.repoVersion = "13"; # Also update kubo-migrator when changing the repo version
passthru.repoVersion = "14"; # Also update kubo-migrator when changing the repo version

# Kubo makes changes to it's source tarball that don't match the git source.
src = fetchurl {
url = "https://github.com/ipfs/kubo/releases/download/${rev}/kubo-source.tar.gz";
hash = "sha256-3Oj/x3EkceNO8/Ik7+U43wi1aL0lYJi1FA0AjtdJRDI=";
hash = "sha256-tS7hiv7KnALR+hCn/TPUwqp/xIOLnQ3ReSb1bNBnwUY=";
};

# tarball contains multiple files/directories
Expand Down