Added some logic to be able to upload cookbooks

As discussed in PR #34