Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 823cd6e8ffc5
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 2e70b40f5873
Choose a head ref
  • 2 commits
  • 2 files changed
  • 2 contributors

Commits on Nov 21, 2018

  1. netlogo: init 6.0.4

    David Pätzel authored and dpaetzel committed Nov 21, 2018
    Copy the full SHA
    fa623ad View commit details

Commits on Nov 22, 2018

  1. Merge pull request #49376 from dpaetzel/package-netlogo

    NetLogo: init 6.0.4
    worldofpeace authored Nov 22, 2018

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    2e70b40 View commit details
Showing with 60 additions and 0 deletions.
  1. +58 −0 pkgs/applications/science/misc/netlogo/default.nix
  2. +2 −0 pkgs/top-level/all-packages.nix
58 changes: 58 additions & 0 deletions pkgs/applications/science/misc/netlogo/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{ jre, stdenv, fetchurl, makeWrapper, makeDesktopItem }:

let

desktopItem = makeDesktopItem rec {
name = "netlogo";
exec = name;
icon = name;
comment = "A multi-agent programmable modeling environment";
desktopName = "NetLogo";
categories = "Science;";
};

in

stdenv.mkDerivation rec {
name = "netlogo-${version}";
version = "6.0.4";

src = fetchurl {
url = "https://ccl.northwestern.edu/netlogo/${version}/NetLogo-${version}-64.tgz";
sha256 = "0dcd9df4dfb218826a74f9df42163fa588908a1dfe58864106936f8dfb76acec";
};

src1 = fetchurl {
name = "netlogo.png";
url = "https://netlogoweb.org/assets/images/desktopicon.png";
sha256 = "1i43lhr31lzva8d2r0dxpcgr58x496gb5vmb0h2da137ayvifar8";
};

nativeBuildInputs = [ makeWrapper ];

installPhase = ''
mkdir -pv $out/share/netlogo $out/share/icons/hicolor/256x256/apps $out/share/applications $out/share/doc
cp -rv app $out/share/netlogo
cp -v readme.md $out/share/doc/
# launcher with `cd` is required b/c otherwise the model library isn't usable
makeWrapper "${jre}/bin/java" "$out/bin/netlogo" \
--run "cd $out/share/netlogo/app" \
--add-flags "-jar netlogo-${version}.jar"
cp $src1 $out/share/icons/hicolor/256x256/apps/netlogo.png
cp ${desktopItem}/share/applications/* $out/share/applications
'';

meta = with stdenv.lib; {
description = "A multi-agent programmable modeling environment";
longDescription = ''
NetLogo is a multi-agent programmable modeling environment. It is used by
many tens of thousands of students, teachers and researchers worldwide.
'';
homepage = https://ccl.northwestern.edu/netlogo/index.shtml;
license = licenses.gpl2;
maintainers = [ maintainers.dpaetzel ];
platforms = platforms.linux;
};
}
2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
@@ -21779,6 +21779,8 @@ with pkgs;

megam = callPackage ../applications/science/misc/megam { };

netlogo = callPackage ../applications/science/misc/netlogo { };

ns-3 = callPackage ../development/libraries/science/networking/ns3 { };

root = callPackage ../applications/science/misc/root {