summary refs log tree commit diff stats
path: root/koch.nim
diff options
context:
space:
mode:
authorAman Gupta <aman@tmm1.net>2015-10-06 11:06:41 -0700
committerAman Gupta <aman@tmm1.net>2015-10-06 11:06:41 -0700
commiteea8d604d07aae569843ebccc5bd7791cff40567 (patch)
treedbb652a24acbf0dfd28e2921f72b0d92fe4a858d /koch.nim
parenta01fd5e93f58a2bf9dea4f577218b8ff7d874bbf (diff)
parent2e413d3186455bf92ee9bae04304cb34cf1f2557 (diff)
downloadNim-eea8d604d07aae569843ebccc5bd7791cff40567.tar.gz
Merge remote-tracking branch 'origin/devel' into fix-test-failures
Diffstat (limited to 'koch.nim')
-rw-r--r--koch.nim9
1 files changed, 7 insertions, 2 deletions
diff --git a/koch.nim b/koch.nim
index 8992271bf..3d1a22b9c 100644
--- a/koch.nim
+++ b/koch.nim
@@ -41,6 +41,7 @@ Options:
 Possible Commands:
   boot [options]           bootstraps with given command line options
   install [bindir]         installs to given directory; Unix only!
+  geninstall               generate ./install.sh; Unix only!
   clean                    cleans Nim project; removes generated files
   web [options]            generates the website and the full documentation
   website [options]        generates only the website
@@ -127,9 +128,12 @@ proc nsis(args: string) =
   exec(("tools" / "niminst" / "niminst --var:version=$# --var:mingw=mingw$#" &
         " nsis compiler/installer.ini") % [VersionAsString, $(sizeof(pointer)*8)])
 
+proc geninstall(args="") =
+  exec("$# cc -r $# --var:version=$# --var:mingw=none --main:compiler/nim.nim scripts compiler/installer.ini $#" %
+       [findNim(), compileNimInst, VersionAsString, args])
+
 proc install(args: string) =
-  exec("$# cc -r $# --var:version=$# --var:mingw=none --main:compiler/nim.nim scripts compiler/installer.ini" %
-       [findNim(), compileNimInst, VersionAsString])
+  geninstall()
   exec("sh ./install.sh $#" % args)
 
 proc web(args: string) =
@@ -373,6 +377,7 @@ of cmdArgument:
   of "zip": zip(op.cmdLineRest)
   of "xz": xz(op.cmdLineRest)
   of "nsis": nsis(op.cmdLineRest)
+  of "geninstall": geninstall(op.cmdLineRest)
   of "install": install(op.cmdLineRest)
   of "test", "tests": tests(op.cmdLineRest)
   of "update":