Skip to content

Commit

Permalink
antares: init at 0.7.22
Browse files Browse the repository at this point in the history
  • Loading branch information
hatch01 committed Mar 27, 2024
1 parent edeff1b commit fa71f23
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions pkgs/by-name/an/antares/package.nix
@@ -0,0 +1,51 @@
{ fetchFromGitHub
, lib
, buildNpmPackage
, electron
, nodejs
}:

buildNpmPackage rec {
pname = "antares";
version = "0.7.22";

src = fetchFromGitHub {
owner = "antares-sql";
repo = "antares";
rev = "v${version}";
hash = "sha256-SYnhrwxoyVw+bwfN1PGMsoul+mTfi8UkiP0fNOvVTBc=";
};

npmDepsHash = "sha256-5khFw8Igu2d5SYLh7OiCpUDMOVH5gAje+VnvoESQboo=";

nativeBuildInputs = [
electron
];

buildInputs = [ nodejs ];

buildPhase = ''
runHook preBuild
npm run compile # this project use typescript so we need to compile it
mkdir -p $out/lib/node_modules/${pname}
cp -r dist/* $out/lib/node_modules/${pname}
runHook postBuild
'';

dontNpmBuild = true;
env.ELECTRON_SKIP_BINARY_DOWNLOAD = "1";
env.PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD = "1";

postInstall = ''
makeWrapper ${electron}/bin/electron $out/bin/${pname} \
--add-flags $out/lib/node_modules/${pname}/main.js
'';

meta = with lib; {
description = "A modern, fast and productivity driven SQL client with a focus in UX ";
homepage = "https://github.com/antares-sql/antares";
license = licenses.mit;
maintainers = with maintainers; [ eymeric ];
platforms = platforms.all;
};
}

0 comments on commit fa71f23

Please sign in to comment.