geminabox 1.4.1 → 1.4.3.rc

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d4cd157b68695f62078fdfe0852c583684149a3df1bf12fe49c77f52786cf814
4
- data.tar.gz: 81190a65a9f11776e07569922f7284a72cece2f5a39fa3a950155276b95f0ad1
3
+ metadata.gz: c44c05f8f334a36f1c3580caa4960ac01d603c1d3493390913e190cd84f562b1
4
+ data.tar.gz: '008ee0518161a2ef8a8f6450bb9626a603253ef8f28b3fbf19dbd0c0af37d1d5'
5
5
  SHA512:
6
- metadata.gz: 48c92617e64fd7abfbe55aee1223f2fa56ee5e6c6436e470b3b491182ccf5508ff259822204c53c32503ce9eb2be38f94e817e4cd0c6e6a3df27814006014f93
7
- data.tar.gz: 4baad42fcfce75ff75411481cf118cde1e991471bb9f650f6869e9ccd68b8078448debcbbd5185b3d8cbe4a5b478e7485de6e8a8e7e615ea6420ed89a45fc34e
6
+ metadata.gz: 30ab306f101a357c39e32e3e6209a9a4da3ac17b65d9465964e1c1ec56eb7a4e37e1f63ac6d22963d840106737c753bcaf3fa9a164aba0f0ea3e72b9528f7f7b
7
+ data.tar.gz: d5201a3b99c33824bf818e776a9fbc440700217bc419ffe24ff8c3f42e99e1a14cb8fddbc60c1ea39c1765516fa7fb99fd27fd718736300666bc87ebb2b77858
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Gem in a Box – Really simple rubygem hosting
2
- [![Build Status](https://secure.travis-ci.org/geminabox/geminabox.png)](http://travis-ci.org/geminabox/geminabox)
3
- [![Gem Version](https://badge.fury.io/rb/geminabox.png)](http://badge.fury.io/rb/geminabox)
2
+ [![Ruby](https://github.com/geminabox/geminabox/actions/workflows/ruby.yml/badge.svg)](https://github.com/geminabox/geminabox/actions/workflows/ruby.yml?query=branch%3Amaster)
3
+ [![Gem Version](https://badge.fury.io/rb/geminabox.svg)](http://badge.fury.io/rb/geminabox)
4
4
  [![Code Climate](https://codeclimate.com/github/geminabox/geminabox/badges/gpa.svg)](https://codeclimate.com/github/geminabox/geminabox)
5
5
 
6
6
  Geminabox lets you host your own gems, and push new gems to it just like with rubygems.org.
@@ -12,7 +12,7 @@ For basic auth, try [Rack::Auth](http://www.rubydoc.info/github/rack/rack/Rack/A
12
12
 
13
13
  ## System Requirements
14
14
 
15
- See [.travis.yml](./.travis.yml) for supported ruby versions
15
+ See [.github/workflows/ruby.yml](.github/workflows/ruby.yml) for supported ruby versions
16
16
 
17
17
  ## Server Setup
18
18
 
@@ -37,12 +37,6 @@ Create a config.ru as follows:
37
37
 
38
38
  Start your gem server with 'rackup' to run WEBrick or hook up the config.ru as you normally would ([passenger](https://www.phusionpassenger.com/), [thin](http://code.macournoyer.com/thin/), [unicorn](https://bogomips.org/unicorn/), whatever floats your boat).
39
39
 
40
- ## Legacy RubyGems index
41
-
42
- RubyGems supports generating indexes for the so called legacy versions (< 1.2), and since it is very rare to use such versions nowadays, it can be disabled, thus improving indexing times for large repositories. If it's safe for your application, you can disable support for these legacy versions by adding the following configuration to your config.ru file:
43
-
44
- Geminabox.build_legacy = false
45
-
46
40
  ## RubyGems Proxy
47
41
 
48
42
  Geminabox can be configured to pull gems, it does not currently have, from rubygems.org. To enable this mode you can either:
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require "fileutils"
2
4
  module Geminabox
3
5
  class Geminabox::DiskCache
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require "set"
2
4
 
3
5
  module Geminabox
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Geminabox
2
4
 
3
5
  class GemStore
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'nesty'
2
4
  module Geminabox
3
5
  class GemStoreError < StandardError
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Geminabox
2
4
 
3
5
  class GemVersion
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Geminabox
2
4
 
3
5
  # This class represents a sorted collection of Geminabox::GemVersion objects.
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'sinatra/base'
2
4
 
3
5
  module Geminabox
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'httpclient'
2
4
 
3
5
  module Geminabox
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'faraday'
2
4
 
3
5
  module Geminabox
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require_relative 'http_adapter_config_error'
2
4
 
3
5
  module Geminabox
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Geminabox
2
4
  class HttpAdapterConfigError < StandardError
3
5
  def initialize(method_name, returns)
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Geminabox
2
4
 
3
5
  class IncomingGem
@@ -1,3 +1,4 @@
1
+ # frozen_string_literal: true
1
2
 
2
3
  # This module addresses Geminabox issue
3
4
  # https://github.com/cwninja/geminabox/issues/70
@@ -1,3 +1,4 @@
1
+ # frozen_string_literal: true
1
2
 
2
3
 
3
4
  module Geminabox
@@ -26,7 +27,7 @@ module Geminabox
26
27
  File.open(proxy_path, 'w'){|f| f.write(rc) }
27
28
  end
28
29
  rescue
29
- File.unlink(proxy_path) if File.exists?(proxy_path)
30
+ File.unlink(proxy_path) if File.exist?(proxy_path)
30
31
  raise $!
31
32
  end
32
33
  end
@@ -1,3 +1,4 @@
1
+ # frozen_string_literal: true
1
2
 
2
3
  module Geminabox
3
4
  module Proxy
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'sinatra/base'
2
4
  require 'net/http'
3
5
 
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'tempfile'
2
4
  require 'fileutils'
3
5
  require 'rubygems/util'
@@ -1,3 +1,4 @@
1
+ # frozen_string_literal: true
1
2
 
2
3
  module Geminabox
3
4
  module Proxy
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'json'
2
4
  require 'uri'
3
5
 
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'reentrant_flock'
2
4
  require 'rubygems/util'
3
5
 
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Geminabox
2
- VERSION = '1.4.1' unless defined? VERSION
4
+ VERSION = '1.4.3.rc' unless defined? VERSION
3
5
  end
data/lib/geminabox.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'rubygems'
2
4
  require 'digest/md5'
3
5
  require 'builder'
@@ -39,7 +41,6 @@ module Geminabox
39
41
  attr_accessor(
40
42
  :data,
41
43
  :public_folder,
42
- :build_legacy,
43
44
  :incremental_updates,
44
45
  :views,
45
46
  :allow_replace,
@@ -57,6 +58,14 @@ module Geminabox
57
58
  :on_gem_received
58
59
  )
59
60
 
61
+ attr_reader :build_legacy
62
+
63
+ def build_legacy=(value)
64
+ warn "Setting `Geminabox.build_legacy` is deprecated and will be removed in the future. Geminbox will always build modern indices"
65
+
66
+ @build_legacy = value
67
+ end
68
+
60
69
  def set_defaults(defaults)
61
70
  defaults.each do |method, default|
62
71
  variable = "@#{method}"
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'uri'
2
4
  require 'cgi'
3
5
  require 'geminabox'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'rubygems/command'
2
4
 
3
5
  class Gem::Commands::InaboxCommand < Gem::Command
@@ -1,2 +1,4 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require "rubygems/command_manager"
2
4
  Gem::CommandManager.instance.register_command :inabox
metadata CHANGED
@@ -1,17 +1,17 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: geminabox
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.1
4
+ version: 1.4.3.rc
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tom Lea
8
8
  - Jack Foy
9
9
  - Rob Nichols
10
10
  - Naotoshi Seo
11
- autorequire:
11
+ autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2021-05-29 00:00:00.000000000 Z
14
+ date: 2022-06-20 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: sinatra
@@ -73,16 +73,16 @@ dependencies:
73
73
  name: faraday
74
74
  requirement: !ruby/object:Gem::Requirement
75
75
  requirements:
76
- - - ">="
76
+ - - "<"
77
77
  - !ruby/object:Gem::Version
78
- version: '0'
78
+ version: '2.0'
79
79
  type: :runtime
80
80
  prerelease: false
81
81
  version_requirements: !ruby/object:Gem::Requirement
82
82
  requirements:
83
- - - ">="
83
+ - - "<"
84
84
  - !ruby/object:Gem::Version
85
- version: '0'
85
+ version: '2.0'
86
86
  - !ruby/object:Gem::Dependency
87
87
  name: reentrant_flock
88
88
  requirement: !ruby/object:Gem::Requirement
@@ -163,7 +163,7 @@ licenses:
163
163
  - MIT-LICENSE
164
164
  metadata:
165
165
  source_code_uri: https://github.com/geminabox/geminabox
166
- post_install_message:
166
+ post_install_message:
167
167
  rdoc_options:
168
168
  - "--main"
169
169
  - README.md
@@ -176,12 +176,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
176
176
  version: '0'
177
177
  required_rubygems_version: !ruby/object:Gem::Requirement
178
178
  requirements:
179
- - - ">="
179
+ - - ">"
180
180
  - !ruby/object:Gem::Version
181
- version: '0'
181
+ version: 1.3.1
182
182
  requirements: []
183
- rubygems_version: 3.1.2
184
- signing_key:
183
+ rubygems_version: 3.1.6
184
+ signing_key:
185
185
  specification_version: 4
186
186
  summary: Really simple rubygem hosting
187
187
  test_files: []