Skip to content

Commit

Permalink
dbvisualizer: init at 24.2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
boldikoller committed Oct 6, 2024
1 parent a79b49d commit f2dcfe0
Showing 1 changed file with 62 additions and 0 deletions.
62 changes: 62 additions & 0 deletions pkgs/by-name/db/dbvisualizer/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{
lib,
makeDesktopItem,
makeWrapper,
stdenv,
temurin-jre-bin-17,
}:

stdenv.mkDerivation (finalAttrs: {
pname = "dbvisualizer";
version = "24.2.2";

src =
let
underscoreVersion = lib.concatStringsSep "_" (lib.splitString "." finalAttrs.version);
in
fetchTarball {
url = "https://www.dbvis.com/product_download/dbvis-${finalAttrs.version}/media/dbvis_linux_${underscoreVersion}.tar.gz";
sha256 = "sha256:17kbf444n21jawr55w4lr0l216rdjf4w3cykj04i1h2hqbjswvp8";
};

nativeBuildInputs = [ makeWrapper ];

strictDeps = true;

desktopEntry = makeDesktopItem {
name = finalAttrs.pname;
desktopName = "DB Visualizer";
tryExec = "dbvis";
exec = "dbvis";
icon = "dbvisualizer";
categories = [ "Development" ];
terminal = false;
keywords = [
"Database"
"SQL"
];
};

installPhase = ''
mkdir -p $out/bin
cp -a . $out
mkdir -p $out/share/
cp -a ${finalAttrs.desktopEntry}/share/applications $out/share
mkdir -p $out/share/icons/hicolor/128x128/apps
ln -s $out/resources/images/tool/dbvis-icon128x128.png \
$out/share/icons/hicolor/128x128/apps/dbvisualizer.png
ln -s $out/dbvis $out/bin
wrapProgram $out/bin/dbvis --set INSTALL4J_JAVA_HOME ${temurin-jre-bin-17}
'';

meta = {
description = "The universal database tool";
homepage = "https://www.dbvis.com/";
maintainers = with lib.maintainers; [ boldikoller ];
license = lib.licenses.unfree;
mainProgram = "dbvis";
};
})

0 comments on commit f2dcfe0

Please sign in to comment.