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

Configurable stub locations #113

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

maddhatter
Copy link

Allow stub paths to be configurable so stubs can be customized.

Unfortunately, the tests are failing because the config() calls can't be resolved. Maybe someone with more test-foo can suggest how to get around that?

@tabacitu
Copy link
Contributor

tabacitu commented Mar 8, 2020

@maddhatter I now have write access and I'll be able to dedicate some time to this repo in the coming days/weeks. I'm planning on releasing a new kickass version 2 #170 and this sounds like a GREAT addition.

Let me know if this is still a package you're using, and you'd like to collaborate on making this PR better, to be able to merge it.

One thing I'd change is to make all paths to the stubs start with Laravel's base_path() helper. So that:

  • the default config value would be vendor/laracasts/generators/src/stubs/migration.stub;
  • developers could change it to stubs/migration.stub if they want to just create a stubs folder in their project; or maybe even ../stubs/migration.stub if they want a GENERAL stubs folder for all their projects;
  • developers are able to generate files from PHP, in controllers and commands;

What do you think about that? Would you like to help make this PR better and launch this feature in v2?

Even if you can't, thanks for taking the time to submit this PR. Less than 1% of all people do this, it's such a kind thing to do.

Cheers!

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

Successfully merging this pull request may close these issues.

2 participants