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

♻️ Improve module naming and directory structure #163

Closed
3 tasks
Glutexo opened this issue Jan 21, 2023 · 3 comments · Fixed by #177
Closed
3 tasks

♻️ Improve module naming and directory structure #163

Glutexo opened this issue Jan 21, 2023 · 3 comments · Fixed by #177

Comments

@Glutexo
Copy link
Owner

Glutexo commented Jan 21, 2023

All things Onigumo need to be inside the Onigumo namespace to avoid name clashes. The Mix project itself is Onigumo.MixProject. No submodules should pollute the global namespace. That results in the following steps:

@nappex
Copy link
Collaborator

nappex commented Jan 21, 2023

There is a link to blog where a guy describes his opinion about files and modules naming conventions.

@Glutexo Glutexo changed the title Improve module naming and directory structure ♻️ Improve module naming and directory structure Jan 24, 2023
@Glutexo
Copy link
Owner Author

Glutexo commented Jan 24, 2023

Regarding the Hash module, I am thinking of a Utilities subnamespace. Having the core three pillars (Downloader, Operator, Parser) separated from auxiliary modules seems elegant, but an overly complex structure brings its issues too. It would look like this:

  • Onigumo.Kernel.Downloader, Onigumo.Kernel.Operator, Onigumo.Kernel.Parser, Onigumo.Kernel.Utilities.Hash or
  • Onigumo.Kernel.Core.Downloader, Onigumo.Kernel.Core.Operator, and Onigumo.Kernel.Core.Parser, Onigumo.Kernel.Utilities.Hash. Kernel.Core sounds fishy: I’d rather see Onigumo.Onigumo.Core or Onigumo.Onigumo.Kernel.

Seeing it live, I find a flat structure less confusing: Onigumo.Kernel.Downloader, Onigumo.Kernel.Operator, Onigumo.Kernel.Parser, Onigumo.Kernel.Hash. We can revisit this when more modules are in place, but even with dozens of modules, a flat structure is still clear enough.

What do you think, @nappex?

@Glutexo
Copy link
Owner Author

Glutexo commented Jan 24, 2023

Thanks for the blog link! It is a good reference, and I find the thoughts on naming the main file for a module with submodules inspiring!

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

Successfully merging a pull request may close this issue.

2 participants