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

Highlight the differences between scripts and modules #1567

Merged
merged 3 commits into from
Oct 1, 2024

Conversation

132ikl
Copy link
Contributor

@132ikl 132ikl commented Sep 30, 2024

Highlights some differences between how scripts and modules handle main, and explains in further detail how and why def main [] {} is required for subcommands to be visible

book/modules.md Outdated Show resolved Hide resolved
Copy link
Contributor

@NotTheDr01ds NotTheDr01ds left a comment

Choose a reason for hiding this comment

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

A few suggestions - I'm still working through the whole thing, and I'll probably check it out into my local repo so that I can view it with the local VuePress server.

book/modules.md Show resolved Hide resolved
book/modules.md Show resolved Hide resolved
book/modules.md Outdated Show resolved Hide resolved
book/modules.md Outdated Show resolved Hide resolved
book/scripts.md Outdated Show resolved Hide resolved
book/scripts.md Show resolved Hide resolved
@132ikl 132ikl marked this pull request as draft September 30, 2024 19:16
Co-authored-by: Douglas <[email protected]>
@132ikl
Copy link
Contributor Author

132ikl commented Sep 30, 2024

@NotTheDr01ds Switched all the blockquotes to tips and implemented your suggestions 😄

@NotTheDr01ds
Copy link
Contributor

NotTheDr01ds commented Sep 30, 2024

@132ikl Thanks! I'd say go with it. I see the key points about the main differences (no pun intended), just a happy accident) and that looks solid. The rest is just formatting and wordsmithing, and I can do another pass on that later and add you as a reviewer.

Also - I'm not quite sure yet, but given what you are point out here, it almost seems to me that we might need some page where we compare and contrast:

  • sourced files
  • Modules
  • Script files

@fdncred fdncred merged commit 68620e2 into nushell:main Oct 1, 2024
2 checks passed
@fdncred
Copy link
Collaborator

fdncred commented Oct 1, 2024

thanks

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