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

src.prefix strips both version and rev and fails the fetch #85

Open
oxalica opened this issue Oct 21, 2022 · 1 comment
Open

src.prefix strips both version and rev and fails the fetch #85

oxalica opened this issue Oct 21, 2022 · 1 comment

Comments

@oxalica
Copy link

oxalica commented Oct 21, 2022

I'm using src.prefix to strip tags like v1.6.10 to get version number 1.6.10.

[swaylock-effects]
src.github_tag = "jirutka/swaylock-effects"
src.prefix = "v"
fetch.github = "jirutka/swaylock-effects"

But it actually strip both version and rev, which contradicts README.

You can tweak obtained version number using this option, e.g. stripping the prefix v or transforming the result by regex.

The fetcher will be called as follows:
> fetchFromGitHub {
>   owner = "jirutka";
>   repo = "swaylock-effects";
>   rev = "1.6.10";
>   sha256 = "sha256:0000000000000000000000000000000000000000000000000000";
> }

trying https://github.com/jirutka/swaylock-effects/archive/1.6.10.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0    14    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 404
@berberman
Copy link
Owner

This is somewhat by design, because the transformation is done by nvchecker, and nvfetcher uses the processed version in later steps. This should be clarified in README. IMO, for the purpose of changing the version number for simply building the derivation, i.e. without affecting fetching and other processes, it wouldn't be harm to do with some string operations in Nix land.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants