-1

我试图将 gem 上传到 Rubygems,但它抛出了这个错误:

$ gem push voxel4r.gemspec -V
GET http://rubygems.org/latest_specs.4.8.gz
302 Moved Temporarily
GET http://production.s3.rubygems.org/latest_specs.4.8.gz
304 Not Modified
Pushing gem to https://rubygems.org...
POST https://rubygems.org/api/v1/gems
422 Unprocessable Entity
RubyGems.org cannot process this gem.
Please try rebuilding it and installing it locally to make sure it's valid.

它已成功构建:

$ gem build voxel4r.gemspec 
  Successfully built RubyGem
  Name: voxel4r
  Version: 0.0.1
  File: voxel4r-0.0.1.gem

我有一个 Rubygems 帐户,并且我有我的~/.gem/credentials文件。我还可以做些什么?

4

1 回答 1

4

我犯了一个错误:

我试图推送 gemspec 文件而不是 gem 文件。

$ gem push voxel4r-0.0.1.gem -V
GET http://rubygems.org/latest_specs.4.8.gz
302 Moved Temporarily
GET http://production.s3.rubygems.org/latest_specs.4.8.gz
200 OK
Pushing gem to https://rubygems.org...
POST https://rubygems.org/api/v1/gems
200 OK
Successfully registered gem: voxel4r (0.0.1)
于 2013-03-26T08:28:26.110 回答