merge from upstream #1

Merged
jyapayne merged 8 commits from master into master 2021-01-23 04:38:37 +00:00
Showing only changes of commit e987b50610 - Show all commits

ensure loaf exists before finding (#256)

n5m 2020-10-15 13:48:39 +00:00 • committed by GitHub
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -416,8 +416,14 @@ proc findFiles*(file: string, dir: string, recurse = true, regex = false): seq[s
## `file` is a regular expression if `regex` is true
##
## Turn off recursive search with `recurse`
let
loafExe = loafExePath()
doAssert fileExists(loafExe), "loaf not compiled: " & loafExe.sanitizePath &
" make sure 'nimble build' or 'nimble install' built it"
var
cmd = loafExePath().quoteShell & " find --rexp $1 \"$2\" $3"
cmd = loafExe.quoteShell & " find --rexp $1 \"$2\" $3"
recursive = if recurse: "--recurse" else: ""
var