diff options
author | Shea Levy <shea@shealevy.com> | 2013-10-16 16:01:27 -0400 |
---|---|---|
committer | Shea Levy <shea@shealevy.com> | 2013-10-16 16:01:27 -0400 |
commit | 418fa3bb330af527e0d48e3f597a296a7d42c461 (patch) | |
tree | b66f83760ba1d17d58c0014d3fbcaa80c8945441 /nixos/modules/programs | |
parent | 6171f13ed573183516fa3a86ca44e0334501b037 (diff) | |
download | nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.tar nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.tar.gz nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.tar.bz2 nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.tar.lz nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.tar.xz nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.tar.zst nixlib-418fa3bb330af527e0d48e3f597a296a7d42c461.zip |
D'oh
Signed-off-by: Shea Levy <shea@shealevy.com>
Diffstat (limited to 'nixos/modules/programs')
-rw-r--r-- | nixos/modules/programs/gurobi.nix | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/nixos/modules/programs/gurobi.nix b/nixos/modules/programs/gurobi.nix index 4c673a96db06..7fa099b0884f 100644 --- a/nixos/modules/programs/gurobi.nix +++ b/nixos/modules/programs/gurobi.nix @@ -23,21 +23,21 @@ in { type = types.nullOr types.string; }; }; + }; - config = mkIf (cfg.license != null || cfg.tokenServerAddress != null) { - assertions = [ { - assertion = cfg.license == null || cfg.tokenServerAddress == null; - message = "Please only set one of a gurobi license file and a gurobi token server address"; - } ]; - - environment.variables.GRB_LICENSE_FILE = if cfg.license != null - then cfg.license - else pkgs.writeTextFile { - name = "gurobi-generated-license"; - text = "TOKENSERVER=${cfg.tokenServerAddress}"; - }; + config = mkIf (cfg.license != null || cfg.tokenServerAddress != null) { + assertions = [ { + assertion = cfg.license == null || cfg.tokenServerAddress == null; + message = "Please only set one of a gurobi license file and a gurobi token server address"; + } ]; + + environment.variables.GRB_LICENSE_FILE = if cfg.license != null + then cfg.license + else pkgs.writeTextFile { + name = "gurobi-generated-license"; + text = "TOKENSERVER=${cfg.tokenServerAddress}"; + }; - environment.systemPackages = [ pkgs.gurobi ]; - }; + environment.systemPackages = [ pkgs.gurobi ]; }; } |