gemfury 0.4.11 → 0.4.12

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -1,174 +1,61 @@
1
1
  Gemfury CLI
2
2
  ===========
3
3
 
4
- [![RubyGem Version](https://fury-badge.herokuapp.com/rb/gemfury.png)](http://badge.fury.io/rb/gemfury)
4
+ [![RubyGem Version](https://badge.fury.io/rb/gemfury.png)](http://badge.fury.io/rb/gemfury)
5
5
  [![Build Status](https://secure.travis-ci.org/gemfury/gemfury.png?branch=master)](https://travis-ci.org/gemfury/gemfury)
6
6
 
7
- Gemfury is your personal cloud for your private and custom RubyGems.
8
- Once you upload your RubyGem and enable Gemfury as a source, you can
9
- securely deploy any gem to any host. It's simple, reliable, and
10
- hassle-free.
7
+ This is the Gemfury CLI used to manage your Gemfury packages from the command line. If you're
8
+ familiar with the service and want to jump straight into command line action, please proceed to
9
+ the [CLI documentation](http://devcenter.gemfury.com/articles/gemfury-cli.html).
11
10
 
12
- Overview
13
- --------
11
+ Gemfury is your personal cloud for your private and custom RubyGems, Python packages, and NPM
12
+ modules. Once you upload your packages and enable Gemfury as a source, you can securely deploy
13
+ any package to any host. It's simple, reliable, and hassle-free.
14
14
 
15
- Gemfury allows you to push your RubyGems to our secure cloud storage
16
- and to deploy them without the need for additional tools or hosting.
17
- Once you [register for a Gemfury account][0], you can start using it by
18
- installing the command-line tool:
19
15
 
20
- $ sudo gem install gemfury
16
+ ### Introduction to Gemfury
17
+ * [Gemfury homepage](http://www.gemfury.com)
18
+ * [Getting started with Gemfury](http://devcenter.gemfury.com/articles/getting-started.html)
21
19
 
22
- And subsequently uploading your first Gem:
20
+ ### Using Gemfury CLI
21
+ * [CLI documentation](http://devcenter.gemfury.com/articles/gemfury-cli.html)
22
+ * [Uploading private packages](http://devcenter.gemfury.com/articles/gemfury-cli.html#uploading_packages)
23
+ * [Manage collaborators](http://devcenter.gemfury.com/articles/gemfury-cli.html#collaboration)
23
24
 
24
- $ fury push private-gem-1.0.0.gem
25
+ ### Putting Gemfury to work
26
+ * [Install private RubyGems](http://devcenter.gemfury.com/articles/install-gems.html)
27
+ * [Install private Python packages](http://devcenter.gemfury.com/articles/pypi-server.html)
28
+ * [Install private NPM modules](http://devcenter.gemfury.com/articles/npm-registry.html)
29
+ * [Private Gems on Heroku](http://devcenter.gemfury.com/articles/private-gems-on-heroku.html)
25
30
 
26
- That's it!
27
31
 
28
- Uploading Gems
29
- --------------
32
+ ## Contribution and Improvements
30
33
 
31
- Uploading your gems is easy. Once you've installed the _gemfury_ gem,
32
- upload gems to your account with:
34
+ Please [email us](mailto:support@gemfury.com) if we've missed some key functionality or you have problems installing the CLI client. Better yet, fork the code, make the changes, and submit a pull request to speed things along.
33
35
 
34
- $ fury push private-gem-1.0.0.gem
36
+ ### Submitting updates
35
37
 
36
- If you are migrating from another gem server, or just have many gems
37
- lying around, you can specify a directory path and we will upload
38
- all the gems found in that directory:
38
+ If you would like to contribute to this project, just do the following:
39
39
 
40
- $ fury migrate ./path/to/gems
40
+ 1. Fork the repo on Github.
41
+ 2. Add your features and make commits to your forked repo.
42
+ 3. Make a pull request to this repo.
43
+ 4. Review will be done and changes will be requested.
44
+ 5. Once changes are done or no changes are required, pull request will be merged.
45
+ 6. The next release will have your changes in it.
41
46
 
42
- Deployment
43
- ----------
47
+ Please take a look at the issues page if you want to get started.
44
48
 
45
- To start installing your gems, you will need to get your secret
46
- Source-URL from your Gemfury Dashboard. It will look like this:
49
+ ### Feature requests
47
50
 
48
- https://gems.gemfury.com/j8e6n7n5n3y09/
49
-
50
- ### Use it with RubyGems command-line
51
-
52
- To use it with the regular RubyGems commands, you can add it as a source
53
- with the following command. This command will store your Gemfury source
54
- in your _~/.gemrc_ file for future use.
55
-
56
- $ gem sources -a https://gems.gemfury.com/j8e6n7n5n3y09/
57
-
58
- You can also do a one-time install with:
59
-
60
- $ gem install private-gem --source https://gems.gemfury.com/j8e6n7n5n3y09/
61
-
62
- ### Use it with Bundler
63
-
64
- Using Gemfury with Bundler is simple as well, just add this to your
65
- Gemfile:
66
-
67
- source 'https://gems.gemfury.com/j8e6n7n5n3y09/'
68
-
69
- Collaboration
70
- -------------
71
-
72
- You can share your Gemfury account with other Gemfury users. Your
73
- collaborators will be able to upload and remove RubyGems without
74
- access to your Secret-URL or the content of previously uploaded gems.
75
-
76
- ### Enable collaboration
77
-
78
- Collaboration is currently only available via the prerelease
79
- command-line tool. To get started, you'll need to install it:
80
-
81
- $ sudo gem install gemfury
82
-
83
- ### Managing collaborators
84
-
85
- Only the account owner can manage collaborators. Collaboration commands
86
- are all grouped under the _sharing_ prefix. For example, to list the
87
- collaborators for your account:
88
-
89
- $ fury sharing
90
-
91
- Adding and removing collaborators is as easy as:
92
-
93
- $ fury sharing:add USERNAME
94
- $ fury sharing:remove USERNAME
95
-
96
- ### Impersonation
97
-
98
- Once you have been added as a collaborator, you can perform Gem
99
- operations as the shared account via the _--as_ option. For example,
100
- to upload a new Gem into the shared account:
101
-
102
- $ fury push another-gem-0.1.0.gem --as USERNAME
103
-
104
- Same is possible with listing and deleting gems:
105
-
106
- $ fury list --as USERNAME
107
- $ fury yank another-gem -v 0.1.0 --as USERNAME
108
-
109
-
110
- Logging-off and more
111
- --------------------
112
-
113
- To remove your Gemfury credentials, or to change the current user,
114
- delete _~/.gems/gemfury_ file or run this command:
115
-
116
- $ fury logout
117
-
118
- You can also list the Gems in your account. Unlike _gem list_, this
119
- command only shows the latest releasable version:
120
-
121
- $ fury list
122
-
123
- To list all available versions of a gem, use this:
124
-
125
- $ fury versions GEMNAME
126
-
127
- You can find out about yanking gems and others commands with:
128
-
129
- $ fury help
130
-
131
-
132
- Using the API client
133
- --------------------
134
-
135
- The API and the API client library (included in this gem as
136
- _Gemfury::Client_) are currently in an unreleased semi-private
137
- undocumented development state. *Enter at your own peril!*
138
-
139
- To start using the client, you'll need to get your API token from
140
- _~/.gem/gemfury_ and initialize the client like so:
141
-
142
- ``` ruby
143
- client = Gemfury::Client.new(:user_api_key => 'j8e6n7n5n3y09')
144
- ```
145
-
146
- Given the above-mentioned state of the API, we leave you with the
147
- exercise of figuring out the rest of the library and API :)
148
-
149
- Stay tuned...
150
-
151
-
152
- Contribution and Improvements
153
- -----------------------------
154
-
155
- Please email us at support@gemfury.com if we've missed some key functionality or if this gem causes conflicts. Better yet, fork the code, make the changes (specs too), and submit a pull request to speed things along.
51
+ If you think it would be nice to have a particular feature that is presently not implemented, we would love
52
+ to hear that and consider working on it. Just open an issue in Github.
156
53
 
157
54
  ### Dependency conflicts
158
55
 
159
56
  Over time, dependencies for this gem will get stale and may interfere with your other gems. Please let us know if you run into this and we will re-test our gem with the new version of the dependency and update the _gemspec_.
160
57
 
161
58
 
162
- Questions
163
- ---------
164
-
165
- Please email support@gemfury.com or file an Issue if you have any
166
- questions or problems.
167
-
168
-
169
- Author
170
- ------
171
-
172
- Michael Rykov :: michael@gemfury.com :: @MichaelRykov
59
+ ## Questions
173
60
 
174
- [0]: http://www.gemfury.com/signup
61
+ Please email support@gemfury.com or file a Github Issue if you have any other questions or problems.
@@ -1,5 +1,6 @@
1
1
  class Gemfury::Command::App < Thor
2
2
  include Gemfury::Command::Authorization
3
+ PackageExtensions = %w(gem egg tar.gz tgz)
3
4
 
4
5
  # Impersonation
5
6
  class_option :as, :desc => 'Access an account other than your own'
@@ -22,18 +23,18 @@ class Gemfury::Command::App < Thor
22
23
  end
23
24
  end
24
25
 
25
- desc "push GEM", "Upload a new version of a gem"
26
+ desc "push FILE", "Upload a new version of a package"
26
27
  def push(*gems)
27
28
  with_checks_and_rescues do
28
29
  push_files(:push, gems)
29
30
  end
30
31
  end
31
32
 
32
- desc "list", "List your gems on Gemfury"
33
+ desc "list", "List your packages"
33
34
  def list
34
35
  with_checks_and_rescues do
35
36
  gems = client.list
36
- shell.say "\n*** GEMFURY GEMS ***\n\n"
37
+ shell.say "\n*** GEMFURY PACKAGES ***\n\n"
37
38
  gems.each do |g|
38
39
  desc, version = g['name'], g.path('latest_version.version')
39
40
  desc << " (#{version ? version : 'beta'})"
@@ -42,7 +43,7 @@ class Gemfury::Command::App < Thor
42
43
  end
43
44
  end
44
45
 
45
- desc "versions GEM", "List all the available gem versions"
46
+ desc "versions NAME", "List all the package versions"
46
47
  def versions(gem_name)
47
48
  with_checks_and_rescues do
48
49
  versions = client.versions(gem_name)
@@ -53,7 +54,7 @@ class Gemfury::Command::App < Thor
53
54
  end
54
55
  end
55
56
 
56
- desc "yank GEM", "Delete a gem version"
57
+ desc "yank NAME", "Delete a package version"
57
58
  method_options %w(version -v) => :required
58
59
  def yank(gem_name)
59
60
  with_checks_and_rescues do
@@ -110,24 +111,24 @@ class Gemfury::Command::App < Thor
110
111
  end
111
112
 
112
113
  ### MIGRATION (Pushing directories) ###
113
- desc "migrate DIR", "Upload all gems within a directory"
114
+ desc "migrate DIR", "Upload all packages within a directory"
114
115
  def migrate(*paths)
115
116
  with_checks_and_rescues do
116
117
  gem_paths = Dir.glob(paths.map do |p|
117
118
  if File.directory?(p)
118
- "#{p}/**/*.gem"
119
+ PackageExtensions.map { |ext| "#{p}/**/*.#{ext}" }
119
120
  elsif File.file?(p)
120
121
  p
121
122
  else
122
123
  nil
123
124
  end
124
- end.compact)
125
+ end.flatten.compact)
125
126
 
126
127
  if gem_paths.empty?
127
- shell.say "Problem: No valid gems found", :red
128
+ shell.say "Problem: No valid packages found", :red
128
129
  help(:migrate)
129
130
  else
130
- shell.say "Found the following RubyGems:"
131
+ shell.say "Found the following packages:"
131
132
  gem_paths.each { |p| shell.say " #{File.basename(p)}" }
132
133
  if shell.yes? "Upload these files to Gemfury? [yN]", :green
133
134
  push_files(:migrate, gem_paths)
@@ -147,8 +148,8 @@ private
147
148
  def with_checks_and_rescues(&block)
148
149
  with_authorization(&block)
149
150
  rescue Gemfury::InvalidGemVersion => e
150
- shell.say "You have a deprecated Gemfury gem", :red
151
- if shell.yes? "Would you like to update this gem now? [yN]"
151
+ shell.say "You have a deprecated Gemfury client", :red
152
+ if shell.yes? "Would you like to update it now? [yN]"
152
153
  exec("gem update gemfury")
153
154
  else
154
155
  shell.say %q(No problem. You can also run "gem update gemfury")
@@ -168,7 +169,7 @@ private
168
169
  end.compact
169
170
 
170
171
  if files.empty?
171
- shell.say "Problem: No valid gems found", :red
172
+ shell.say "Problem: No valid packages found", :red
172
173
  help(command)
173
174
  return
174
175
  end
@@ -180,7 +181,7 @@ private
180
181
  client.push_gem(file)
181
182
  shell.say "- done"
182
183
  rescue Gemfury::CorruptGemFile
183
- shell.say "- problem processing this gem", :red
184
+ shell.say "- problem processing this package", :red
184
185
  rescue Gemfury::TimeoutError, Errno::EPIPE
185
186
  shell.say "- this file is too much to handle", :red
186
187
  shell.say " Visit http://www.gemfury.com/large-package for more info"
@@ -1,3 +1,3 @@
1
1
  module Gemfury
2
- VERSION = '0.4.11'
3
- end
2
+ VERSION = '0.4.12'
3
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gemfury
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.11
4
+ version: 0.4.12
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-01-18 00:00:00.000000000 Z
12
+ date: 2013-02-15 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: highline
@@ -148,8 +148,8 @@ files:
148
148
  homepage: http://www.gemfury.com
149
149
  licenses: []
150
150
  post_install_message: ! "************************************************************************\n\n
151
- \ Upload your first gem to start using Gemfury:\n fury push my-gem-1.0.gem\n\n
152
- \ If you have a directory with gems, you can use:\n fury migrate ./path/to/gems\n\n
151
+ \ Upload your first package to start using Gemfury:\n fury push my-package-1.0.0.gem\n\n
152
+ \ If you have a directory with packages, you can use:\n fury migrate ./path/to/codez\n\n
153
153
  \ Find out what else you can do:\n fury help\n\n Follow @gemfury on Twitter for
154
154
  announcements, updates, and news.\n https://twitter.com/gemfury\n\n************************************************************************\n"
155
155
  rdoc_options: []