A user ran kobweb run in the root of their new Kobweb project and got the error "This is not a Kobweb application module"
What the user needed to do was do: cd site; kobweb run (or kobweb run -p site) but they didn't realize that.
It would be nice to inform the user of their mistake more clearly than a generic error. Maybe something like.
This is not a Kobweb application module.
A Kobweb application module was found in the site/ subfolder. Consider navigating in there and running kobweb run again.
Note that...
A project might have their kobweb application under a differently named subfolder.
A project might have multiple kobweb applications in their project.
So on one end, we can just look for "site/.kobweb" and report if that is found, since that's 99.99% of all cases. Or we can do something more general and walk their directory structure, maybe max 1 or 2 levels deep, looking for .kobweb folders.
Then:
This is not a Kobweb application module.
A Kobweb application module was found in the app/ subfolder. Consider navigating in there and running kobweb run again.
or
This is not a Kobweb application module.
Kobweb application modules were found in the following folders:
site/free
site/paid
Consider navigating into one of them and running kobweb run again.
A user ran
kobweb run
in the root of their new Kobweb project and got the error "This is not a Kobweb application module"What the user needed to do was do:
cd site; kobweb run
(orkobweb run -p site
) but they didn't realize that.It would be nice to inform the user of their mistake more clearly than a generic error. Maybe something like.
Note that...
So on one end, we can just look for "site/.kobweb" and report if that is found, since that's 99.99% of all cases. Or we can do something more general and walk their directory structure, maybe max 1 or 2 levels deep, looking for .kobweb folders.
Then:
or