summaryrefslogtreecommitdiff
path: root/pkgs/by-name/cu/curlie/package.nix
blob: 0d26874856cdf7211707b8bd933f44d3f616bcf0 (about) (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
{
  lib,
  buildGoModule,
  fetchFromGitHub,
  curlie,
  testers,
}:

buildGoModule (finalAttrs: {
  pname = "curlie";
  version = "1.8.2";

  src = fetchFromGitHub {
    owner = "rs";
    repo = "curlie";
    tag = "v${finalAttrs.version}";
    hash = "sha256-BlpIDik4hkU4c+KCyAmgUURIN362RDQID/qo6Ojp2Ek=";
  };

  vendorHash = "sha256-GBccl8V87u26dtrGpHR+rKqRBqX6lq1SBwfsPvj/+44=";

  ldflags = [
    "-s"
    "-w"
    "-X main.version=${finalAttrs.version}"
  ];

  passthru.tests.version = testers.testVersion {
    package = curlie;
    command = "curlie version";
  };

  meta = {
    description = "Frontend to curl that adds the ease of use of httpie, without compromising on features and performance";
    homepage = "https://curlie.io/";
    maintainers = with lib.maintainers; [ ma27 ];
    license = lib.licenses.mit;
    mainProgram = "curlie";
  };
})