- 
      
- 
        Save ryangraham/2210025 to your computer and use it in GitHub Desktop. 
    Re-write Opscode Cookbooks as individual Git repos
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | #!/bin/bash | |
| for cookbook in $(find * -type d -maxdepth 0); do | |
| git clone ./ ../${cookbook} | |
| cd ../${cookbook} | |
| git remote rm origin | |
| git filter-branch --subdirectory-filter ${cookbook} -- --all | |
| git gc --aggressive | |
| done | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment