diff options
-rw-r--r-- | README.md | 1 | ||||
-rw-r--r-- | packages/nix/NIX.md | 31 |
2 files changed, 32 insertions, 0 deletions
@@ -13,6 +13,7 @@ Several source build packages are available, along with experimental pre-built g <a href='https://flathub.org/apps/details/org.polymc.PolyMC'><img width='240' alt='Download on Flathub' src='https://flathub.org/assets/badges/flathub-badge-en.png'/></a> <br> [](https://aur.archlinux.org/packages/polymc-git/) +- A [Nix](packages/nix/NIX.md) derivation is available in repo. - A Gentoo ebuild is available in the [swirl](https://git.swurl.xyz/swirl/ebuilds) overlay, named `games-action/polymc`. Check the README for instructions on how to add the overlay. - The Flatpak can be built using [this source](https://github.com/flathub/org.polymc.PolyMC). - An RPM package is available, by going to the `packages/rpm` directory and running `./makerpm.sh`. diff --git a/packages/nix/NIX.md b/packages/nix/NIX.md new file mode 100644 index 00000000..f778dac1 --- /dev/null +++ b/packages/nix/NIX.md @@ -0,0 +1,31 @@ +# How to import + +To import with flakes use +```nix +inputs = { + polymc.url = "github:PolyMC/PolyMC"; +}; + +... + +nixpkgs.overlays = [ inputs.polymc.overlay.${system} ]; ## Within configuration.nix +environment.systemPackages = with pkgs; [ polymc ]; ## +``` + +To import without flakes use channels: + +``` +nix-channel --add https://github.com/PolyMC/PolyMC/archive/master.tar.gz polymc +nix-channel --update polymc +nix-env -iA polymc +``` + +or alternatively you can use + +``` +nixpkgs.overlays = [ + (import (builtins.fetchTarball "https://github.com/PolyMC/PolyMC/archive/develop.tar.gz")).overlay +]; + +environment.systemPackages = with pkgs; [ polymc ]; +```
\ No newline at end of file |