Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Genie.loadapp ignores path argument in case of app.jl #733

Open
schlichtanders opened this issue Feb 12, 2025 · 2 comments
Open

Genie.loadapp ignores path argument in case of app.jl #733

schlichtanders opened this issue Feb 12, 2025 · 2 comments
Assignees

Comments

@schlichtanders
Copy link

When starting Genie via Genie.loadapp("path/to/my/project"), it always assumes that app.jl and probably other files too are located in the current directory and not in path/to/my/project.

The underlying problem is that the path is not at all forwarded to the autoloader, which does not use paths, but relies on the current directory instead.

Background: It would be nice to have a Genie app MyGenieApp with main function, package it, and let others add the package and call MyGenieApp.main(), which necessarily needs to make sure that the package's app.jl files are used and those from the user's current directory.

@schlichtanders
Copy link
Author

It would probably even better if specifying the context to a specific module other than Main would look for everything in the route folder of that project. But I am not an expert in Genie details, so might be that this is not an option

@essenciary
Copy link
Member

@schlichtanders Thanks. Don't fully understand the use case. Can you give me an actual example?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants