-
-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
linode-cli: init at 1.4.7 #23080
linode-cli: init at 1.4.7 #23080
Conversation
src = fetchgit { | ||
url = "git://github.com/linode/cli"; | ||
rev = "8d475f3ff161b64dbe1aff167897974f92475a3c"; | ||
sha256 = "1c24c7n3fq9c3yibw1i4zlk3hdcjaqcd5cq4kvvw4hfg2l3w6a21"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use fetchFromGitHub
here instead of fetchgit
|
||
src = fetchgit { | ||
url = "git://github.com/linode/cli"; | ||
rev = "8d475f3ff161b64dbe1aff167897974f92475a3c"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use the version as revision here: https://github.com/linode/cli/releases
rev = "v${version}";
outputs = [ "out" ]; | ||
|
||
# Has no tests | ||
doCheck = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The package sill misses dependencies:
Warning: prerequisite JSON 0 not found.
Warning: prerequisite LWP::UserAgent 0 not found.
Warning: prerequisite Mozilla::CA 0 not found.
Warning: prerequisite Try::Tiny 0 not found.
Warning: prerequisite WebService::Linode 0 not found.
effa0e2
to
060115a
Compare
So it looks like my initial attempt at packaging this was pretty naive, but the binary worked surprisingly well all things considered. I have included all the libraries and am using fetchFromGitHub now, but I am a bit stumped on a library path issue. When I try and run some of the executables I get the following: Can't locate Linode/CLI.pm in I am not terribly familiar with Perl so I am not sure how the |
You might need to wrap the executable, using some variation of
|
sha256 = "1wiz067wgxi4z4rz4n9p7dlvx5z4hkl2nxpfvhikl6dri4m2nkkp"; | ||
}; | ||
|
||
# src = fetchgit { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove this
# }; | ||
|
||
# Has no docs output | ||
outputs = [ "out" ]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the default
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The default outputs appears to contain "devdoc" at well which caused this build to fail.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, that must be a perl thing
pkgs/top-level/perl-packages.nix
Outdated
@@ -14958,4 +14958,19 @@ let self = _self // overrides; _self = with self; { | |||
}; | |||
}; | |||
|
|||
WebServiceLinode = buildPerlModule rec { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add this package in a separate commit with the message: perlPackages.WebServiceLinode: init at 0.28
bacc724
to
3ff63bd
Compare
I believe this should be good now. Thanks a bunch ya'll. Learning about all kinds of fun Nix functions that make life easier. |
Anything else I need to do here? |
The travis build fails, can you investigate? Other than that it also needs a rebase. |
doCheck = false; | ||
|
||
# # Has no docs output | ||
# outputs = [ "out" ]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think Perl packages are expected to have devdoc
output, but there is none in this case, which causes the failure.
I made the changes suggested and I believe the travis build should run, but it looks like Travis rejected my build. It looks like it gave the following errors:
Anyone know what I can do to prevent that? |
Motivation for this change
Want to make the Linode-CLI available through Nix, because Nix is the best :)
Things done
(nix.useSandbox on NixOS,
or option
build-use-sandbox
innix.conf
on non-NixOS)
nix-shell -p nox --run "nox-review wip"
./result/bin/
)