Skip to content

Commit

Permalink
deepsource: init at 0.8.6 (#324286)
Browse files Browse the repository at this point in the history
  • Loading branch information
Aleksanaa authored Nov 3, 2024
2 parents d2313c4 + 75d4c78 commit 500a82d
Show file tree
Hide file tree
Showing 2 changed files with 68 additions and 0 deletions.
6 changes: 6 additions & 0 deletions maintainers/maintainer-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15580,6 +15580,12 @@
githubId = 3159451;
name = "Nicolas Schneider";
};
nipeharefa = {
name = "Nipe Harefa";
email = "[email protected]";
github = "nipeharefa";
githubId = 12620257;
};
NIS = {
name = "NSC IT Solutions";
github = "dev-nis";
Expand Down
62 changes: 62 additions & 0 deletions pkgs/by-name/de/deepsource/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{
lib,
stdenv,
installShellFiles,
buildGoModule,
fetchFromGitHub,
versionCheckHook,
}:

buildGoModule rec {
pname = "deepsource";
version = "0.8.6";

src = fetchFromGitHub {
owner = "DeepSourceCorp";
repo = "cli";
rev = "v${version}";
hash = "sha256-6uNb4cQVerrlW/eUkjmlO1i1YKYX3qaVdo0i5cczt+I=";
};

nativeBuildInputs = [ installShellFiles ];

doCheck = true;

checkFlags =
let
# Skip tests that require network access
skippedTests = [
"TestReportKeyValueWorkflow"
"TestReportAnalyzerTypeWorkflow"
"TestReportKeyValueFileWorkflow"
];
in
[ "-skip=^${builtins.concatStringsSep "$|^" skippedTests}$" ];

vendorHash = "sha256-SsMq4ngq3sSOL28ysHTxTF4CT9sIcCIW7yIhBxIPrNs=";

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

postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd deepsource \
--bash <($out/bin/deepsource completion bash) \
--fish <($out/bin/deepsource completion fish) \
--zsh <($out/bin/deepsource completion zsh)
'';

nativeInstallCheckInputs = [
versionCheckHook
];

meta = {
description = "Command line interface to DeepSource, the code health platform";
mainProgram = "deepsource";
homepage = "https://github.com/DeepSourceCorp/cli";
license = lib.licenses.bsd2;
maintainers = with lib.maintainers; [ nipeharefa ];
};
}

0 comments on commit 500a82d

Please sign in to comment.