Paths

A Koru program declares its own import aliases in source — there is no config file. std/compiler:paths maps an alias to a directory, and import lines resolve against it:

std/compiler:paths {
    domain: {{ ENTRY }}/test_lib/domain
}

import domain/user

domain/user:announce()

That is a whole program. The compiler prepends import std/compiler at line 0 of every program, so the std/compiler namespace is live before any line you write exists — paths simply arrives early enough to resolve the imports below it.

A path segment can interpolate ENTRY — the entry file’s directory — so paths are written relative to the program that declares them, not the working directory koruc happens to run in.

std and app are built in; everything else is declared by the program that uses it.