diff options
author | Thom May <thom@may.lt> | 2015-09-29 11:44:04 -0700 |
---|---|---|
committer | Thom May <thom@may.lt> | 2015-09-29 11:44:04 -0700 |
commit | bc82c3e8603f6908d80fc29beb1d0902563398e7 (patch) | |
tree | 4b990e3ec6848ab247e0c524414c94ca45f4fa9c | |
parent | 20a10906633f3e79627c37a1e280bcc6bee3de64 (diff) | |
parent | f0976789c8e810e8e8cf938f950975affda73446 (diff) | |
download | chef-bc82c3e8603f6908d80fc29beb1d0902563398e7.tar.gz |
Merge pull request #3978 from tas50/knife-wording-2
Community site -> Supermarket in knife
-rw-r--r-- | distro/common/html/knife_cookbook_site.html | 36 | ||||
-rw-r--r-- | distro/common/man/man1/knife-cookbook-site.1 | 22 | ||||
-rw-r--r-- | lib/chef/cookbook_site_streaming_uploader.rb | 2 | ||||
-rw-r--r-- | lib/chef/knife/cookbook_create.rb | 2 | ||||
-rw-r--r-- | lib/chef/knife/cookbook_site_download.rb | 2 | ||||
-rw-r--r-- | lib/chef/knife/cookbook_site_install.rb | 2 | ||||
-rw-r--r-- | lib/chef/knife/cookbook_site_share.rb | 12 | ||||
-rw-r--r-- | lib/chef/knife/search.rb | 4 | ||||
-rw-r--r-- | lib/chef/knife/ssh.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/cookbook_site_share_spec.rb | 6 |
10 files changed, 45 insertions, 45 deletions
diff --git a/distro/common/html/knife_cookbook_site.html b/distro/common/html/knife_cookbook_site.html index 8815961629..60efafa7e1 100644 --- a/distro/common/html/knife_cookbook_site.html +++ b/distro/common/html/knife_cookbook_site.html @@ -5,12 +5,12 @@ <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> - + <title>knife cookbook site — chef-client Man Pages</title> - + <link rel="stylesheet" href="_static/guide.css" type="text/css" /> <link rel="stylesheet" href="_static/pygments.css" type="text/css" /> - + <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT: './', @@ -32,13 +32,13 @@ </div> - + <div class="document"> <div class="documentwrapper"> <div class="body"> - + <div class="section" id="knife-cookbook-site"> <h1>knife cookbook site<a class="headerlink" href="#knife-cookbook-site" title="Permalink to this headline">ΒΆ</a></h1> <p>The Cookbooks Site API is used to provide access to the cookbooks community hosted at <a class="reference external" href="https://supermarket.getchef.com/cookbooks">https://supermarket.getchef.com/cookbooks</a>. All of the cookbooks in the community are accessible through a RESTful API located at <a class="reference external" href="https://supermarket.getchef.com/api/v1/cookbooks">https://supermarket.getchef.com/api/v1/cookbooks</a> by using any of the supported endpoints. In most cases, using knife and the <strong>knife cookbook site</strong> sub-command (and any of its arguments) is the recommended method of interacting with these cookbooks, but in some cases, using the Cookbooks Site API directly may make sense.</p> @@ -228,17 +228,17 @@ ant iis redmine </div> <p>to return something like:</p> <div class="highlight-bash"><div class="highlight"><pre>apache2: - cookbook: http://cookbooks.opscode.com/api/v1/cookbooks/apache2 + cookbook: https://supermarket.chef.io/api/v1/cookbooks/apache2 cookbook_description: Installs and configures apache2 using Debian symlinks with helper definitions cookbook_maintainer: opscode cookbook_name: apache2 instiki: - cookbook: http://cookbooks.opscode.com/api/v1/cookbooks/instiki + cookbook: https://supermarket.chef.io/api/v1/cookbooks/instiki cookbook_description: Installs instiki, a Ruby on Rails wiki server under passenger+Apache2. cookbook_maintainer: jtimberman cookbook_name: instiki kickstart: - cookbook: http://cookbooks.opscode.com/api/v1/cookbooks/kickstart + cookbook: https://supermarket.chef.io/api/v1/cookbooks/kickstart cookbook_description: Creates apache2 vhost and serves a kickstart file. cookbook_maintainer: opscode cookbook_name: kickstart @@ -311,18 +311,18 @@ category: Networking created_at: 2009-10-25T23:51:07Z description: Installs and configures haproxy external_url: -latest_version: http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_3 +latest_version: https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_3 maintainer: opscode name: haproxy updated_at: 2011-06-30T21:53:25Z versions: - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_3 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_2 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_1 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_0 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/0_8_1 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/0_8_0 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/0_7_0 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_3 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_2 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_1 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_0 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/0_8_1 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/0_8_0 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/0_7_0 </pre></div> </div> <p><strong>Show cookbook data as JSON</strong></p> @@ -364,7 +364,7 @@ versions: </div> - + <div class="clearer"></div> </div> @@ -372,4 +372,4 @@ versions: </body> -</html>
\ No newline at end of file +</html> diff --git a/distro/common/man/man1/knife-cookbook-site.1 b/distro/common/man/man1/knife-cookbook-site.1 index a90a5305f0..acfcf6b882 100644 --- a/distro/common/man/man1/knife-cookbook-site.1 +++ b/distro/common/man/man1/knife-cookbook-site.1 @@ -364,17 +364,17 @@ to return something like: .nf .ft C apache2: - cookbook: http://cookbooks.opscode.com/api/v1/cookbooks/apache2 + cookbook: https://supermarket.chef.io/api/v1/cookbooks/apache2 cookbook_description: Installs and configures apache2 using Debian symlinks with helper definitions cookbook_maintainer: opscode cookbook_name: apache2 instiki: - cookbook: http://cookbooks.opscode.com/api/v1/cookbooks/instiki + cookbook: https://supermarket.chef.io/api/v1/cookbooks/instiki cookbook_description: Installs instiki, a Ruby on Rails wiki server under passenger+Apache2. cookbook_maintainer: jtimberman cookbook_name: instiki kickstart: - cookbook: http://cookbooks.opscode.com/api/v1/cookbooks/kickstart + cookbook: https://supermarket.chef.io/api/v1/cookbooks/kickstart cookbook_description: Creates apache2 vhost and serves a kickstart file. cookbook_maintainer: opscode cookbook_name: kickstart @@ -481,18 +481,18 @@ category: Networking created_at: 2009\-10\-25T23:51:07Z description: Installs and configures haproxy external_url: -latest_version: http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_3 +latest_version: https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_3 maintainer: opscode name: haproxy updated_at: 2011\-06\-30T21:53:25Z versions: - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_3 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_2 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_1 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/1_0_0 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/0_8_1 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/0_8_0 - http://cookbooks.opscode.com/api/v1/cookbooks/haproxy/versions/0_7_0 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_3 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_2 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_1 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/1_0_0 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/0_8_1 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/0_8_0 + https://supermarket.chef.io/api/v1/cookbooks/haproxy/versions/0_7_0 .ft P .fi .UNINDENT diff --git a/lib/chef/cookbook_site_streaming_uploader.rb b/lib/chef/cookbook_site_streaming_uploader.rb index 0302a51165..2be189e942 100644 --- a/lib/chef/cookbook_site_streaming_uploader.rb +++ b/lib/chef/cookbook_site_streaming_uploader.rb @@ -26,7 +26,7 @@ require 'openssl' class Chef # == Chef::CookbookSiteStreamingUploader # A streaming multipart HTTP upload implementation. Used to upload cookbooks - # (in tarball form) to http://cookbooks.opscode.com + # (in tarball form) to https://supermarket.chef.io # # inspired by http://stanislavvitvitskiy.blogspot.com/2008/12/multipart-post-in-ruby.html class CookbookSiteStreamingUploader diff --git a/lib/chef/knife/cookbook_create.rb b/lib/chef/knife/cookbook_create.rb index e17a54079f..97f6e65d3c 100644 --- a/lib/chef/knife/cookbook_create.rb +++ b/lib/chef/knife/cookbook_create.rb @@ -48,7 +48,7 @@ class Chef option :cookbook_copyright, :short => "-C COPYRIGHT", :long => "--copyright COPYRIGHT", - :description => "Name of Copyright holder" + :description => "Name of copyright holder" option :cookbook_email, :short => "-m EMAIL", diff --git a/lib/chef/knife/cookbook_site_download.rb b/lib/chef/knife/cookbook_site_download.rb index c2d72ef8da..3e586e6542 100644 --- a/lib/chef/knife/cookbook_site_download.rb +++ b/lib/chef/knife/cookbook_site_download.rb @@ -84,7 +84,7 @@ class Chef end def download_cookbook - ui.info "Downloading #{@name_args[0]} from the cookbooks site at version #{version} to #{download_location}" + ui.info "Downloading #{@name_args[0]} from Supermarket at version #{version} to #{download_location}" noauth_rest.sign_on_redirect = false tf = noauth_rest.get_rest desired_cookbook_data["file"], true diff --git a/lib/chef/knife/cookbook_site_install.rb b/lib/chef/knife/cookbook_site_install.rb index d0ab6da3ef..aee8b7fa94 100644 --- a/lib/chef/knife/cookbook_site_install.rb +++ b/lib/chef/knife/cookbook_site_install.rb @@ -93,7 +93,7 @@ class Chef # TODO: it'd be better to store these outside the cookbook repo and # keep them around, e.g., in ~/Library/Caches on OS X. - ui.info("removing downloaded tarball") + ui.info("Removing downloaded tarball") File.unlink(upstream_file) if @repo.finalize_updates_to(@cookbook_name, downloader.version) diff --git a/lib/chef/knife/cookbook_site_share.rb b/lib/chef/knife/cookbook_site_share.rb index efd2e7f129..beb98b71b8 100644 --- a/lib/chef/knife/cookbook_site_share.rb +++ b/lib/chef/knife/cookbook_site_share.rb @@ -48,7 +48,7 @@ class Chef :short => '-n', :boolean => true, :default => false, - :description => "Don't take action, only print what files will be upload to SuperMarket." + :description => "Don't take action, only print what files will be uploaded to Supermarket." def run config[:cookbook_path] ||= Chef::Config[:cookbook_path] @@ -94,7 +94,7 @@ class Chef Chef::Log.debug("Removing local staging directory at #{tmp_cookbook_dir}") FileUtils.rm_rf tmp_cookbook_dir rescue => e - ui.error("Error uploading cookbook #{cookbook_name} to the Opscode Cookbook Site: #{e.message}. Increase log verbosity (-VV) for more information.") + ui.error("Error uploading cookbook #{cookbook_name} to Supermarket: #{e.message}. Increase log verbosity (-VV) for more information.") Chef::Log.debug("\n#{e.backtrace.join("\n")}") exit(1) end @@ -108,15 +108,15 @@ class Chef def get_category(cookbook_name) begin - data = noauth_rest.get_rest("http://cookbooks.opscode.com/api/v1/cookbooks/#{@name_args[0]}") + data = noauth_rest.get_rest("https://supermarket.chef.io/api/v1/cookbooks/#{@name_args[0]}") if !data["category"] && data["error_code"] - ui.fatal("Received an error from the Opscode Cookbook site: #{data["error_code"]}. On the first time you upload it, you are required to specify the category you want to share this cookbook to.") + ui.fatal("Received an error from Supermarket: #{data["error_code"]}. On the first time you upload it, you are required to specify the category you want to share this cookbook to.") exit(1) else data['category'] end rescue => e - ui.fatal("Unable to reach Opscode Cookbook Site: #{e.message}. Increase log verbosity (-VV) for more information.") + ui.fatal("Unable to reach Supermarket: #{e.message}. Increase log verbosity (-VV) for more information.") Chef::Log.debug("\n#{e.backtrace.join("\n")}") exit(1) end @@ -136,7 +136,7 @@ class Chef if http_resp.code.to_i != 201 if res['error_messages'] if res['error_messages'][0] =~ /Version already exists/ - ui.error "The same version of this cookbook already exists on the Opscode Cookbook Site." + ui.error "The same version of this cookbook already exists on Supermarket." exit(1) else ui.error "#{res['error_messages'][0]}" diff --git a/lib/chef/knife/search.rb b/lib/chef/knife/search.rb index 2b0c79ff6c..014fc8dd87 100644 --- a/lib/chef/knife/search.rb +++ b/lib/chef/knife/search.rb @@ -136,7 +136,7 @@ class Chef def read_cli_args if config[:query] if @name_args[1] - ui.error "please specify query as an argument or an option via -q, not both" + ui.error "Please specify query as an argument or an option via -q, not both" ui.msg opt_parser exit 1 end @@ -145,7 +145,7 @@ class Chef else case name_args.size when 0 - ui.error "no query specified" + ui.error "No query specified" ui.msg opt_parser exit 1 when 1 diff --git a/lib/chef/knife/ssh.rb b/lib/chef/knife/ssh.rb index bb3d9d78bb..62af853e88 100644 --- a/lib/chef/knife/ssh.rb +++ b/lib/chef/knife/ssh.rb @@ -425,7 +425,7 @@ class Chef begin require 'appscript' rescue LoadError - STDERR.puts "you need the rb-appscript gem to use knife ssh macterm. `(sudo) gem install rb-appscript` to install" + STDERR.puts "You need the rb-appscript gem to use knife ssh macterm. `(sudo) gem install rb-appscript` to install" raise end diff --git a/spec/unit/knife/cookbook_site_share_spec.rb b/spec/unit/knife/cookbook_site_share_spec.rb index 76e4ec730e..a7caca9744 100644 --- a/spec/unit/knife/cookbook_site_share_spec.rb +++ b/spec/unit/knife/cookbook_site_share_spec.rb @@ -78,21 +78,21 @@ describe Chef::Knife::CookbookSiteShare do it 'should not fail when given only 1 argument and can determine category' do @knife.name_args = ['cookbook_name'] - expect(@noauth_rest).to receive(:get_rest).with("http://cookbooks.opscode.com/api/v1/cookbooks/cookbook_name").and_return(@category_response) + expect(@noauth_rest).to receive(:get_rest).with("https://supermarket.chef.io/api/v1/cookbooks/cookbook_name").and_return(@category_response) expect(@knife).to receive(:do_upload) @knife.run end it 'should print error and exit when given only 1 argument and cannot determine category' do @knife.name_args = ['cookbook_name'] - expect(@noauth_rest).to receive(:get_rest).with("http://cookbooks.opscode.com/api/v1/cookbooks/cookbook_name").and_return(@bad_category_response) + expect(@noauth_rest).to receive(:get_rest).with("https://supermarket.chef.io/api/v1/cookbooks/cookbook_name").and_return(@bad_category_response) expect(@knife.ui).to receive(:fatal) expect { @knife.run }.to raise_error(SystemExit) end it 'should print error and exit when given only 1 argument and Chef::REST throws an exception' do @knife.name_args = ['cookbook_name'] - expect(@noauth_rest).to receive(:get_rest).with("http://cookbooks.opscode.com/api/v1/cookbooks/cookbook_name") { raise Errno::ECONNREFUSED, "Connection refused" } + expect(@noauth_rest).to receive(:get_rest).with("https://supermarket.chef.io/api/v1/cookbooks/cookbook_name") { raise Errno::ECONNREFUSED, "Connection refused" } expect(@knife.ui).to receive(:fatal) expect { @knife.run }.to raise_error(SystemExit) end |