def upload(cookbook, extended_metadata = false)
      connection.post('cookbooks', {
        'tarball'  => cookbook.tarball(extended_metadata),

        # This is for legacy, backwards-compatability reasons. The new
        # Supermarket site does not require a category, but many of the testing
        # tools still assume a cookbook category is present. We just hardcode
        # "Other" here.
        'cookbook' => JSON.fast_generate(category: 'Other'),
      })
    end
def upload(cookbook, extended_metadata = false)
      connection.post('cookbooks', {
        'tarball'  => cookbook.tarball(extended_metadata),

        # This is for legacy, backwards-compatability reasons. The new
        # Supermarket site does not require a category, but many of the testing
        # tools still assume a cookbook category is present. We just hardcode
        # "Other" here.
        'cookbook' => JSON.fast_generate(category: 'Other'),
      })
    end
Upload a cookbook to the community site.

 @param [Cookbook] cookbook
   the cookbook to upload