snyk: move to by-name and modernize derivation (#343726)

This commit is contained in:
Aleksana 2024-09-22 23:22:56 +08:00 committed by GitHub
commit 360425ea16
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 18 additions and 14 deletions

View File

@ -1,14 +1,18 @@
{ lib
, buildNpmPackage
, fetchFromGitHub
, stdenv
, testers
, snyk
{
lib,
buildNpmPackage,
fetchFromGitHub,
stdenv,
testers,
snyk,
}:
buildNpmPackage rec {
pname = "snyk";
let
version = "1.1293.1";
in
buildNpmPackage {
pname = "snyk";
inherit version;
src = fetchFromGitHub {
owner = "snyk";
@ -26,7 +30,9 @@ buildNpmPackage rec {
env.NIX_CFLAGS_COMPILE =
# Fix error: no member named 'aligned_alloc' in the global namespace
lib.optionalString (stdenv.isDarwin && stdenv.isx86_64) "-D_LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION=1";
lib.optionalString (
stdenv.isDarwin && stdenv.isx86_64
) "-D_LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION=1";
npmBuildScript = "build:prod";
@ -34,12 +40,12 @@ buildNpmPackage rec {
package = snyk;
};
meta = with lib; {
meta = {
description = "Scans and monitors projects for security vulnerabilities";
homepage = "https://snyk.io";
changelog = "https://github.com/snyk/cli/releases/tag/v${version}";
license = licenses.asl20;
maintainers = [ ];
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ momeemt ];
mainProgram = "snyk";
};
}

View File

@ -18632,8 +18632,6 @@ with pkgs;
snore = callPackage ../tools/misc/snore { };
snyk = callPackage ../development/tools/analysis/snyk { };
snzip = callPackage ../tools/archivers/snzip { };
snowman = qt5.callPackage ../development/tools/analysis/snowman { };