aptly-api 0.10.0 → 0.10.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ef67a756d6233d6522678531b0b0b221303a19120b14d80c834e62ad04b061f3
4
- data.tar.gz: bc8c50900970fcd89e47302d43f49e9b6b3c6fd34d008e8f34b9c473c2a71856
3
+ metadata.gz: 1620dd9faac56d2cdc59e3c4fa5071269dfa3fb500ca6837d0c5c2095dfbc793
4
+ data.tar.gz: 9010ab42e434fa472f990a4d8d69a519bbf7989597a9e6c826aae988997d533c
5
5
  SHA512:
6
- metadata.gz: bf61c4b10714a527b5cf699ca9f9e77dd0cee51ce8e8a23f8d6f59b70bdb136091a1c3422ac1c39093038188fc5d6ccb4ca91c84fd7f42c08be48f3aa2b6f541
7
- data.tar.gz: 1baed9a8971546a8c41a8101e56ec07e66a4d8a7eb801b1fcb5ac844afdd6f9ed7f8e0ef46bde5cfd5d75598b6915909c6420cdb7ea7d32f44e47b599fc19a0c
6
+ metadata.gz: 120c7e010476239efb0f3148aaa7871875ec959372d5de59bf29693c2440856f62b5170c6aa9f3d910ae61648a5afc10d8ea88b1283204220e2abd97419d17a5
7
+ data.tar.gz: 719edccb1abff82d097c269631f15b3d56b1cdb809d121bda40c08b6dbe8032a461aa90010241ec7c7e2c0e385a65dbb9668eb226d5fe1120883a88ec6ae43eb
@@ -1,9 +1,5 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 2.2.1
4
- - 2.3.0
5
- - 2.4.0
6
3
  - 2.5.0
7
- before_install:
8
- - gem update --system
9
- - gem install bundler -v 1.10.6
4
+ - 2.6.0
5
+ - 2.7.0
@@ -1,5 +1,12 @@
1
1
  # Change Log
2
2
 
3
+ ## [0.10.1]
4
+ ### Fixed
5
+ - Publishing endpoint escaping no longer creates invalid URIs when the Prefix
6
+ already contains underscores. Prefix=foo_bar is now correctly escaped to
7
+ foo__bar.
8
+ - excon 0.71 is now required as earlier versions had open security issues.
9
+
3
10
  ## [0.10.0]
4
11
  ### Added
5
12
  - `PublishedRepository#from_repositories` publishes repository sources
data/README.md CHANGED
@@ -3,7 +3,6 @@
3
3
  [![Inline docs](http://inch-ci.org/github/KDEJewellers/aptly-api.svg?branch=master)](http://inch-ci.org/github/KDEJewellers/aptly-api)
4
4
  [![Build Status](https://travis-ci.org/KDEJewellers/aptly-api.svg?branch=master)](https://travis-ci.org/KDEJewellers/aptly-api)
5
5
  [![Coverage Status](https://coveralls.io/repos/KDEJewellers/aptly-api/badge.svg?branch=master&service=github)](https://coveralls.io/github/KDEJewellers/aptly-api?branch=master)
6
- [![Dependency Status](https://gemnasium.com/KDEJewellers/aptly-api.svg)](https://gemnasium.com/KDEJewellers/aptly-api)
7
6
  [![Code Climate](https://codeclimate.com/github/KDEJewellers/aptly-api/badges/gpa.svg)](https://codeclimate.com/github/KDEJewellers/aptly-api)
8
7
 
9
8
  ## Installation
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
19
19
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
20
20
  spec.require_paths = ['lib']
21
21
 
22
- spec.add_development_dependency 'bundler', '~> 1.10'
22
+ spec.add_development_dependency 'bundler', '~> 2.0'
23
23
  spec.add_development_dependency 'coveralls', '~> 0.8'
24
24
  spec.add_development_dependency 'minitest', '~> 5.8'
25
25
  spec.add_development_dependency 'rake', '~> 12.0'
@@ -29,5 +29,5 @@ Gem::Specification.new do |spec|
29
29
  spec.add_development_dependency 'yard', '~> 0.8'
30
30
 
31
31
  spec.add_dependency 'faraday', '~> 0.9'
32
- spec.add_dependency 'excon', '~> 0.54'
32
+ spec.add_dependency 'excon', '~> 0.71'
33
33
  end
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2015-2018 Harald Sitter <sitter@kde.org>
1
+ # Copyright (C) 2015-2020 Harald Sitter <sitter@kde.org>
2
2
  #
3
3
  # This library is free software; you can redistribute it and/or
4
4
  # modify it under the terms of the GNU Lesser General Public
@@ -44,8 +44,9 @@ module Aptly
44
44
 
45
45
  # Publish 1 or more sources into a public repository prefix.
46
46
  # @param sources [Array<Repository>] array of repositories to source
47
- # @param prefix [String] the prefix to publish under (must be escaped see
48
- # {.escape_prefix})
47
+ # @param prefix [String] prefix to publish under (i.e. published repo name).
48
+ # This must be escaped (see {Aptly.escape_prefix})
49
+ # @see Aptly.escape_prefix
49
50
  # @param source_kind [String] the source kind (local or snapshot)
50
51
  # @return [PublishedRepository] newly published repository
51
52
  def publish(sources, prefix = '', source_kind = 'local',
@@ -68,7 +69,7 @@ module Aptly
68
69
  # @return [String] API-safe prefix notation
69
70
  # @since 0.7.0
70
71
  def escape_prefix(prefix_path)
71
- prefix_path.tr('_', '__').tr('/', '_')
72
+ prefix_path.gsub('_', '__').tr('/', '_')
72
73
  end
73
74
  end
74
75
  end
@@ -95,7 +95,9 @@ module Aptly
95
95
 
96
96
  # Convenience wrapper around {Aptly.publish}, publishing this repository
97
97
  # locally and as only source of prefix.
98
- # @param prefix [String] prefix to publish under (i.e. published repo name)
98
+ # @param prefix [String] prefix to publish under (i.e. published repo name).
99
+ # This must be escaped (see {Aptly.escape_prefix})
100
+ # @see Aptly.escape_prefix
99
101
  # @return [PublishedRepository] newly published repository
100
102
  def publish(prefix, **kwords)
101
103
  Aptly.publish([{ Name: self.Name }], prefix, 'local', kwords)
@@ -47,7 +47,9 @@ module Aptly
47
47
 
48
48
  # Convenience wrapper around {Aptly.publish}, publishing this snapshot
49
49
  # locally and as only source of prefix.
50
- # @param prefix [String] prefix to publish under (i.e. published snapshot name)
50
+ # @param prefix [String] prefix to publish under (i.e. published repo name).
51
+ # This must be escaped (see {Aptly.escape_prefix})
52
+ # @see Aptly.escape_prefix
51
53
  # @return [PublishedRepository] newly published repository
52
54
  def publish(prefix, **kwords)
53
55
  Aptly.publish([{ Name: self.Name }], prefix, 'snapshot', kwords)
@@ -1,5 +1,5 @@
1
1
  # Aptly API
2
2
  module Aptly
3
3
  # The loaded version of the gem.
4
- VERSION = '0.10.0'.freeze
4
+ VERSION = '0.10.1'.freeze
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aptly-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.10.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Harald Sitter
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2018-03-26 00:00:00.000000000 Z
12
+ date: 2020-10-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -17,14 +17,14 @@ dependencies:
17
17
  requirements:
18
18
  - - "~>"
19
19
  - !ruby/object:Gem::Version
20
- version: '1.10'
20
+ version: '2.0'
21
21
  type: :development
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - "~>"
26
26
  - !ruby/object:Gem::Version
27
- version: '1.10'
27
+ version: '2.0'
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: coveralls
30
30
  requirement: !ruby/object:Gem::Requirement
@@ -143,14 +143,14 @@ dependencies:
143
143
  requirements:
144
144
  - - "~>"
145
145
  - !ruby/object:Gem::Version
146
- version: '0.54'
146
+ version: '0.71'
147
147
  type: :runtime
148
148
  prerelease: false
149
149
  version_requirements: !ruby/object:Gem::Requirement
150
150
  requirements:
151
151
  - - "~>"
152
152
  - !ruby/object:Gem::Version
153
- version: '0.54'
153
+ version: '0.71'
154
154
  description: REST client for the Aptly API
155
155
  email:
156
156
  - sitter@kde.org
@@ -201,8 +201,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
201
201
  - !ruby/object:Gem::Version
202
202
  version: '0'
203
203
  requirements: []
204
- rubyforge_project:
205
- rubygems_version: 2.7.3
204
+ rubygems_version: 3.1.2
206
205
  signing_key:
207
206
  specification_version: 4
208
207
  summary: REST client for the Aptly API