-
Notifications
You must be signed in to change notification settings - Fork 187
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
Vendor Namespace and Package Name should be StudlyCased in the namespace #36
Comments
I have seen Laravel packages work without studlycases. It is not programmatically required, and that is why I leave it up to you to define the capitals. Or at least it was that way when I designed Packager. That is also why all examples in the readme have capitals. |
I guess the problem is that there is no way to generate both a lowercase directory name with a corresponding StudlyCased namespace. I have to manually edit the namespace in all the generated files. The nice thing to have here would be the ability to specify the directory name and the namespace separately (with sane defaults). |
Changing the directory to lowercase would only require changing the app composer.json I think. However, I would accept a PR that fixes this. |
Closed, waiting for Pull Request. |
The namespace may be StudyCap cased, but the vendor name and package name and their directories should be lower case. You can call the directories whatever you like in the Namespaces and vendor/package names, are two completely different things. For example, the "laravel/framework" vendor/package name provides the "\Illuminate" namespace. |
I would welcome a Pull Request. |
I was trying this package today 17th November, 2018 and I seriously couldn't create a package with |
And still no one makes a PR. |
The vendor namespace and package name should be lowercased in the directory tree, but they should be StudlyCased in the class definition.
When I run:
The Expected result is:
Should create a namespace of namespace definition of
Tokenly\FluentdLogger;
The actual Result is:
Creates
namespace tokenly\fluentd-logger;
Here is an example of capitilization in a Laravel vendor package:
The text was updated successfully, but these errors were encountered: