[CHEF-3330] Added functionality to create standard chef repo out of knife#322
[CHEF-3330] Added functionality to create standard chef repo out of knife#322amateurhuman wants to merge 9 commits into
Conversation
|
Thank you for supporting Chef! Our process has a couple prerequisites before we can merge your contribution. We need to ensure you've completed a Contributor License Agreement (CLA) and a ticket on our ticket tracker for the release workflow. Pull requests are optional, but should always include the ticket number that they're related to for cross-referencing. Please take a moment to review the below wiki page for the appropriate steps: |
|
Sorry for not getting these done beforehand, CLA submitted and ticket has been created for feature. |
|
@amateurhuman could you link this PR to the ticket you created in JIRA please? |
|
related ticket: http://tickets.opscode.com/browse/CHEF-3330 |
|
@amateurhuman If you're not going to be able to return to this, could you please close the pull request? |
|
Closed this PR since there was not too much activity on it for the last year. Check out https://tickets.opscode.com/browse/CHEF-3330?focusedCommentId=44702&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-44702 for an alternative way of achieving the overall goal of getting a chef repo created automatically. |
http://tickets.opscode.com/browse/CHEF-3330
The current way to get a canonical chef repository is to create it yourself (which is error prone) or clone it from opscode/chef-repo. There are two problems with cloning the chef-repo:
I built out the functionality as a knife task (
knife repo create NAME) to automate the creation of the directory structure and standard files (readmes and Rakefile). You can pass-p /path/to/repoto create the repo in a different directory than the current one.I didn't include any tests, since it is just building a directory and file structure without any dynamic elements. I mirrored how this was done from the
knife cookbook createtask.The only thing I don't really like is keeping the text of the files in the methods themselves and I am more than open to suggestions for improving that.