Skip to content

Try to search for the lib/ in the working directory as well #205

@SuperFola

Description

@SuperFola

Very often we have bad error messages (see #204) because we don't know where the lib/ folder is.

The thing is, some user will have the ARKSCRIPT_PATH pointing to a folder where the lib/ is. Some other will want to feed the lib directory path through [-L|--lib path], that's fine. But for the ones who have a unique lib/ in the working directory, they either need to setup the environment variable or feed it to the --lib and that's annoying because you just have an error "couldn't load x" or "couldn't find file bla.ark".

We should first look for the ARKSCRIPT_PATH environment variable, then look in the provided --lib option, if any, and finally look in the working directory.

What needs to be modified:

  • State (maybe)
  • Parser (for sure)
  • VM (for sure)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions