diff --git a/flake.nix b/flake.nix index 6b8a76eec..50d6eaf82 100644 --- a/flake.nix +++ b/flake.nix @@ -11,7 +11,6 @@ flake-utils.lib.eachDefaultSystem (system: let pkgs = import nixpkgs { inherit system; overlays = [ rust-overlay.overlays.default ]; }; - # import solana packages solanaPkgs = pkgs.callPackage ./solana.nix {}; in { formatter = pkgs.nixpkgs-fmt; @@ -19,16 +18,13 @@ devShells = { default = pkgs.callPackage ./shell.nix { inherit pkgs; - scriptDir = toString ./.; # converts the flakes'root dir to string + scriptDir = toString ./.; }; - # interactive shell with Solana CLI tool accessibility solana-cli = solanaPkgs.solana-cli-shell; }; packages = { - # dockerized Solana test validator solana-test-validator = solanaPkgs.solana-test-validator; - # environment package for Solana CLI solana-cli-env = solanaPkgs.solana-cli-env; }; }); diff --git a/solana.nix b/solana.nix index 23a077ae1..8af470213 100644 --- a/solana.nix +++ b/solana.nix @@ -3,8 +3,7 @@ pkgs ? import { inherit system; }, }: -# It provides two derivations, one for x86_64-linux and another for aarch64-apple-darwin. -# Each derivation downloads the corresponding Solana release. +# Solana integration let version = "v1.18.22"; getBinDerivation = @@ -27,6 +26,8 @@ let ''; }; + # It provides two derivations, one for x86_64-linux and another for aarch64-apple-darwin. + # Each derivation downloads the corresponding Solana release. solanaBinaries = { x86_64-linux = getBinDerivation { name = "solana-cli-x86_64-linux"; @@ -52,7 +53,7 @@ in ]; }; - # Provides interactive shell with Solana CLI tool accessibility. + # Provides interactive dev shell with Solana CLI tool accessibility. solana-cli-shell = pkgs.mkShell { buildInputs = pkgs.lib.optionals pkgs.stdenv.isLinux [ solanaBinaries.x86_64-linux @@ -73,8 +74,7 @@ in ''; }; - # Provides dockerized Solana test validator accessibility. - # https://hub.docker.com/r/solanalabs/solana/ + # Provides dockerized Solana test validator accessibility. https://hub.docker.com/r/solanalabs/solana # Currently the official docker image only supports x86_64-linux.(https://github.com/anza-xyz/agave/tree/master/sdk/docker-solana) solana-test-validator = pkgs.stdenv.mkDerivation rec { name = "solana-test-validator";