summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/documentation/README.md6
-rw-r--r--lib/bundler/gem_helper.rb18
-rw-r--r--man/bundle.ronn3
3 files changed, 17 insertions, 10 deletions
diff --git a/doc/documentation/README.md b/doc/documentation/README.md
index 7ebb05401c..43ca6f7587 100644
--- a/doc/documentation/README.md
+++ b/doc/documentation/README.md
@@ -16,13 +16,13 @@ Not sure where to write documentation? In general, follow these guidelines:
If you are unsure where to begin, ping [@feministy](https://github.com/feministy) or [@indirect](https://github.com/indirect) in the Bundler Slack ([get an invite here](../contributing/GETTING_HELP.md)).
-## [Writing docs for man pages)](WRITING.md)
+## [Writing docs for man pages](WRITING.md)
-If you’d like to submit a patch to the man pages, you're in the right place! Details on editing and previewing changes to man pages can be found here.
+If you’d like to submit a patch to the man pages, you're in the right place! Details on editing and previewing changes to man pages can be found [here](WRITING.md).
## [Documentation vision](VISION.md)
-Just like Bundler, we have a grand plan (really, a wish list of sorts) for Bundler documentation. Preview our hopes and dreams for our documentation here.
+Just like Bundler, we have a grand plan (really, a wish list of sorts) for Bundler documentation. Preview our hopes and dreams for our documentation [here](VISION.md).
## Translations
diff --git a/lib/bundler/gem_helper.rb b/lib/bundler/gem_helper.rb
index 3c1680a194..6a0906a200 100644
--- a/lib/bundler/gem_helper.rb
+++ b/lib/bundler/gem_helper.rb
@@ -50,7 +50,7 @@ module Bundler
install_gem(built_gem_path, :local)
end
- desc "Create tag #{version_tag} and build and push #{name}-#{version}.gem to RubyGems\n" \
+ desc "Create tag #{version_tag} and build and push #{name}-#{version}.gem to #{gem_push_host}\n" \
"To prevent publishing in RubyGems use `gem_push=no rake release`"
task "release", [:remote] => ["build", "release:guard_clean",
"release:source_control_push", "release:rubygem_push"] do
@@ -92,18 +92,14 @@ module Bundler
protected
def rubygem_push(path)
- allowed_push_host = nil
gem_command = "gem push '#{path}'"
gem_command += " --key #{gem_key}" if gem_key
- if @gemspec.respond_to?(:metadata)
- allowed_push_host = @gemspec.metadata["allowed_push_host"]
- gem_command += " --host #{allowed_push_host}" if allowed_push_host
- end
+ gem_command += " --host #{allowed_push_host}" if allowed_push_host
unless allowed_push_host || Bundler.user_home.join(".gem/credentials").file?
raise "Your rubygems.org credentials aren't set. Run `gem push` to set them."
end
sh(gem_command)
- Bundler.ui.confirm "Pushed #{name} #{version} to #{allowed_push_host ? allowed_push_host : "rubygems.org."}"
+ Bundler.ui.confirm "Pushed #{name} #{version} to #{gem_push_host}"
end
def built_gem_path
@@ -116,6 +112,14 @@ module Bundler
Bundler.ui.confirm "Pushed git commits and tags."
end
+ def allowed_push_host
+ @gemspec.metadata["allowed_push_host"] if @gemspec.respond_to?(:metadata)
+ end
+
+ def gem_push_host
+ allowed_push_host || "rubygems.org"
+ end
+
def perform_git_push(options = "")
cmd = "git push #{options}"
out, code = sh_with_code(cmd)
diff --git a/man/bundle.ronn b/man/bundle.ronn
index e75d861269..9e42e046a7 100644
--- a/man/bundle.ronn
+++ b/man/bundle.ronn
@@ -48,6 +48,9 @@ We divide `bundle` subcommands into primary commands and utilities.
## UTILITIES
+* `bundle add(1)`:
+ Add the named gem to the Gemfile and run `bundle install`
+
* `bundle binstubs(1)`:
Generate binstubs for executables in a gem