Import statement

I decided to put all “typedefs” in external module and to “import" it in the main module. But when I try to compile it it fails with an error:
module ‘external-types.yang’ not found

In which directory should I put it? Can I configure the location of this file? I would like them to be located in the same directory.

It looks like you did “import external-types.yang”, you just need to type “import external-types”.

For the second question, the same directory is fine, more directories can be specified as parameters to the compiler.

That helped. Thank you.