diff --git a/.gitignore b/.gitignore index 155f12f..4829058 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ nimcache -*.exe \ No newline at end of file +nimgen +*.exe diff --git a/.nimgen.nim.swp b/.nimgen.nim.swp new file mode 100644 index 0000000..d726a7c Binary files /dev/null and b/.nimgen.nim.swp differ diff --git a/nimgen b/nimgen deleted file mode 100755 index b397c47..0000000 Binary files a/nimgen and /dev/null differ diff --git a/nimgen.nim b/nimgen.nim index 1ebdcb2..d55099a 100644 --- a/nimgen.nim +++ b/nimgen.nim @@ -246,7 +246,7 @@ proc c2nim(fl, outfile, flags, ppflags: string, recurse, preproc, ctag, define: if recurse: var incls = getincls(file) for inc in incls: - incout &= "import " & inc.splitFile().name & "\n" + incout &= "import " & inc.splitFile().name.replace(re"[-_\.]", "") & "\n" c2nim(inc, getnimout(inc), flags, ppflags, recurse, preproc, ctag, define, compile, dynlib) var cfile = file