living in unix-land, eye to eye, where nothing ever works; fixes #12226
This commit is contained in:
parent
e0f2b3ba8f
commit
39185b46ca
1 changed files with 6 additions and 2 deletions
|
|
@ -473,12 +473,16 @@ proc getOutFile*(conf: ConfigRef; filename: RelativeFile, ext: string): Absolute
|
||||||
conf.outDir / changeFileExt(filename, ext)
|
conf.outDir / changeFileExt(filename, ext)
|
||||||
|
|
||||||
proc absOutFile*(conf: ConfigRef): AbsoluteFile =
|
proc absOutFile*(conf: ConfigRef): AbsoluteFile =
|
||||||
conf.outDir / conf.outFile
|
result = conf.outDir / conf.outFile
|
||||||
|
if dirExists(result.string):
|
||||||
|
result.string.add ".out"
|
||||||
|
|
||||||
proc prepareToWriteOutput*(conf: ConfigRef): AbsoluteFile =
|
proc prepareToWriteOutput*(conf: ConfigRef): AbsoluteFile =
|
||||||
## Create the output directory and returns a full path to the output file
|
## Create the output directory and returns a full path to the output file
|
||||||
createDir conf.outDir
|
createDir conf.outDir
|
||||||
return conf.outDir / conf.outFile
|
result = conf.outDir / conf.outFile
|
||||||
|
if dirExists(result.string):
|
||||||
|
result.string.add ".out"
|
||||||
|
|
||||||
proc getPrefixDir*(conf: ConfigRef): AbsoluteDir =
|
proc getPrefixDir*(conf: ConfigRef): AbsoluteDir =
|
||||||
## Gets the prefix dir, usually the parent directory where the binary resides.
|
## Gets the prefix dir, usually the parent directory where the binary resides.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue