about summary refs log tree commit diff
path: root/pkgs/tools/misc/archi
diff options
context:
space:
mode:
authorJames Earl Douglas <james@earldouglas.com>2020-12-01 10:55:48 -0700
committerGitHub <noreply@github.com>2020-12-01 18:55:48 +0100
commit1a3557f729a1615a27e8da75ea930a27c635f381 (patch)
treea08c3abaf29462b01f211360d735713d8aac93ba /pkgs/tools/misc/archi
parent2d55b8def4b8e4882123cae432bdea2c89e72166 (diff)
archi: init at 4.7.1 (#103355)
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
Diffstat (limited to 'pkgs/tools/misc/archi')
-rw-r--r--pkgs/tools/misc/archi/default.nix61
1 files changed, 61 insertions, 0 deletions
diff --git a/pkgs/tools/misc/archi/default.nix b/pkgs/tools/misc/archi/default.nix
new file mode 100644
index 0000000000000..41562ccbf7110
--- /dev/null
+++ b/pkgs/tools/misc/archi/default.nix
@@ -0,0 +1,61 @@
+{ stdenv
+, fetchurl
+, fetchzip
+, autoPatchelfHook
+, libsecret
+}:
+
+stdenv.mkDerivation rec {
+  pname = "Archi";
+  version = "4.7.1";
+
+  src =
+    if stdenv.hostPlatform.system == "x86_64-linux" then
+      fetchurl {
+        url = "https://www.archimatetool.com/downloads/archi/Archi-Linux64-${version}.tgz";
+        sha256 = "0sd57cfnh5q2p17sd86c8wgmqyipg29rz6iaa5brq8mwn8ps2fdw";
+      }
+    else if stdenv.hostPlatform.system == "x86_64-darwin" then
+      fetchzip {
+        url = "https://www.archimatetool.com/downloads/archi/Archi-Mac-${version}.zip";
+        sha256 = "1h05lal5jnjwm30dbqvd6gisgrmf1an8xf34f01gs9pwqvqfvmxc";
+      }
+    else
+      throw "Unsupported system";
+
+  buildInputs = [
+    libsecret
+  ];
+
+  nativeBuildInputs = [
+    autoPatchelfHook
+  ];
+
+  installPhase =
+    if stdenv.hostPlatform.system == "x86_64-linux" then
+      ''
+      mkdir -p $out/bin
+        for f in configuration features p2 plugins Archi.ini Archi; do
+          cp $f $out/bin/
+        done
+
+        install -D -m755 Archi $out/bin/Archi
+      ''
+    else
+      ''
+        mkdir -p "$out/Applications"
+        mv Archi.app "$out/Applications/"
+      '';
+
+  meta = with stdenv.lib; {
+    description = "ArchiMate modelling toolkit";
+    longDescription = ''
+      Archi is an open source modelling toolkit to create ArchiMate
+      models and sketches.
+    '';
+    homepage = "https://www.archimatetool.com/";
+    license = licenses.mit;
+    platforms = platforms.linux ++ platforms.darwin;
+    maintainers = with maintainers; [ earldouglas SuperSandro2000 ];
+  };
+}