Skip to content

Conversation

giacomocavalieri
Copy link
Member

This PR improves the help text for the run, dev, and test command by saying which function they're going to run in the help text. This is something people usually ignore, especially for gleam test, thinking it's doing more than it actually does. So maybe this could help clear some confusion (given someone will read the help text 😆)

Copy link
Member

@lpil lpil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the idea, but I'm not a huge fan of the syntax used here, and the line slightly long.

What does gleam help look like with this?

@giacomocavalieri
Copy link
Member Author

gleam help hasn't changed:
Screenshot 2025-10-03 alle 13 31 17
While gleam test/dev/main --help looks like this:
Screenshot 2025-10-03 alle 13 31 30

@lpil
Copy link
Member

lpil commented Oct 3, 2025

Maybe we should specify the module name instead of the file, since it doesn't have to be at that path.

@giacomocavalieri
Copy link
Member Author

I had no idea this was the case, so gleam dev runs the main function from the<PROJECT_NAME>_dev module regardless of where the module is? Does that work even if the module is under src/ or test/?

@GearsDatapacks
Copy link
Member

That's correct. No distinction is made there

@giacomocavalieri
Copy link
Member Author

I see, so should we only suggest the module name? @lpil how would you prefer that information be presented, is <PACKAGE_NAME>_dev ok?

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

Successfully merging this pull request may close these issues.

3 participants