diff options
| author | coast <coasteen@proton.me> | 2026-09-07 04:24:28 +0330 |
|---|---|---|
| committer | coast <coasteen@proton.me> | 2026-09-07 04:24:28 +0330 |
| commit | a3b4fcff8da036382d45a71516c07fce28d1bca7 (patch) | |
| tree | c5527f2208641fded9ab29969814768095c83f37 /home-configuration/managed/mindustry/default.nix | |
| parent | 61a4eb7165428365b790e188b61e3cb419b84afe (diff) | |
| download | nix-a3b4fcff8da036382d45a71516c07fce28d1bca7.tar.gz nix-a3b4fcff8da036382d45a71516c07fce28d1bca7.tar.bz2 nix-a3b4fcff8da036382d45a71516c07fce28d1bca7.tar.xz nix-a3b4fcff8da036382d45a71516c07fce28d1bca7.tar.zst | |
update
Diffstat (limited to 'home-configuration/managed/mindustry/default.nix')
| -rw-r--r-- | home-configuration/managed/mindustry/default.nix | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/home-configuration/managed/mindustry/default.nix b/home-configuration/managed/mindustry/default.nix new file mode 100644 index 0000000..929bca7 --- /dev/null +++ b/home-configuration/managed/mindustry/default.nix @@ -0,0 +1,25 @@ +{ pkgs, ... }: +let + version = "159.7"; + src = pkgs.fetchurl { + url = "https://github.com/Anuken/Mindustry/releases/download/v${version}/Mindustry.jar"; + hash = "sha256:67b2e5c7575e564b184ed11e139c01ddc140afd28b238715e7d42e81612fdfbe"; + }; + icon = pkgs.fetchurl { + url = "https://upload.wikimedia.org/wikipedia/commons/4/4a/Mindustry_Icon.png"; + hash = "sha256:1s597ywczx5c92dnqkij6drzkpn92613fqqsc1imw7dbhf07xjml"; + }; + mindustry = pkgs.writeShellScriptBin "mindustry" '' + export LD_LIBRARY_PATH=${pkgs.libglvnd}/lib:$LD_LIBRARY_PATH + exec ${pkgs.jdk17}/bin/java -jar ${src} "$@" + ''; +in +{ + home.packages = [ mindustry ]; + home.file.".local/share/icons/hicolor/scalable/apps/mindustry.png".source = icon; + xdg.desktopEntries.mindustry.comment = "Sandbox tower defense with factory automation"; + xdg.desktopEntries.mindustry.name = "Mindustry"; + xdg.desktopEntries.mindustry.genericName = "Tower defense game"; + xdg.desktopEntries.mindustry.exec = "mindustry"; + xdg.desktopEntries.mindustry.icon = "mindustry"; +} |
