Is there a “default” file name that can be used for importing modules?
What I mean is if there's some standard name that can be used for the primary file in a local Nim module so that when importing by path, we can simply reference the directory? For example, it seems right now I need to specify both the directory and file name of the local module like this: import my_module.main Whereas I was hoping to simply be able to reference the directory if the expected file name was found: import my_module Aside from using Nimble or creating a separate --path flag for every module in a nim.cfg file, is there anything that will allow this? Also, in general, is there a conventional name to use for the main file of a module? If I have a simple app like this: myapp--+ | +--myapp.nim | +--sub--+ | +--sub.nim In myapp.nim I have to use import sub.sub to load the sub-module. With import sub, I get Error: cannot open sub. Likewise if I have modules outside the app and set the --path to the parent of those modules, I have to use import my_module.my_module.
The idea is to have a my_module.nim and sub-modules in a my_module directory. Then you can just import my_module.
what is nim type definition for generic procedure?
Does a nim library contain an argsort implementation or wrapper?
nim jester how to change static route and directory
nim linker error while linking to libsodium
Can countup and countdown iterators in Nim language be used in variable declaration?
How do I write unit test for code that should fail to compile in Nim?
Difference between void proc and void proc with discard
nim nimscript is not executing commands
Remove element at index from sequence
Is it possible / easy to include some mruby in a nim application?
Reading bytes from many files performance
Program doesn't compile when “concept” defines a method with a parameter
How do I create a directory?
Why is my string nil?
Nim code parser
What's the meaning of “magic” pragma in nim?