jekyll-avatar 0.6.0 → 0.7.0

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
- SHA1:
3
- metadata.gz: 006e20723e8e73f4a452c08cc145cdc56aee0a14
4
- data.tar.gz: dc445c24979eeb27748772ebd0a07720f6f0e3d4
2
+ SHA256:
3
+ metadata.gz: 1a22ab2c587db15659207e8bda5a6f1b26f5040516a865023e56e7de08b79564
4
+ data.tar.gz: 9e96126073cb90638e4d7222d754a137736117a63af230b50e9f9e778f5e66e3
5
5
  SHA512:
6
- metadata.gz: b1a217149b137448b584fc36b9cba53fc1c50d59649b50e6f03a59e94b7e34f7f772d1612f0b7c8e58eece9dca18663cb14c0978b5181934cf3274806859b5a9
7
- data.tar.gz: 39f9071c7869a4741e7fb5c497230b905f81ae01984693ad5720fa87ed6285bd071333815c77847ccec867e5d59f0b9f0b2ad45e51b9cd91c29d08ec0dd27ef4
6
+ metadata.gz: 5627bdf38d43d0c59764fd15d807eae1fdadf27c5b8eaf744adf49f46ab18f47b961c91ada518e02d4344a0e8e39ee79a0f9b457eeeb703549e11f6e00e30172
7
+ data.tar.gz: 2ce4d723bec13ff6386d2d773efad6c039f6ab73bfd44f3797184bf53fefad6fd0ab71839a3407e8400e79ab57f1eb51b8ac71265600b8ea07422ac3f2c943d4
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: Bug report
3
+ about: Create a report to help us improve
4
+
5
+ ---
6
+
7
+ ### Describe the bug
8
+
9
+ A clear and concise description of what the bug is.
10
+
11
+ ### Steps to reproduce the behavior
12
+
13
+ 1. Go to '...'
14
+ 2. Click on '....'
15
+ 3. Scroll down to '....'
16
+ 4. See error
17
+
18
+ ### Expected behavior
19
+
20
+ A clear and concise description of what you expected to happen.
21
+
22
+ ### Screenshots
23
+
24
+ If applicable, add screenshots to help explain your problem.
25
+
26
+ ### Additional context
27
+
28
+ Add any other context about the problem here.
@@ -0,0 +1,21 @@
1
+ ---
2
+ name: Feature request
3
+ about: Suggest an idea for this project
4
+
5
+ ---
6
+
7
+ ### Is your feature request related to a problem? Please describe the problem you're trying to solve.
8
+
9
+ A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
10
+
11
+ ### Describe the solution you'd like
12
+
13
+ A clear and concise description of what you want to happen.
14
+
15
+ ### Describe alternatives you've considered
16
+
17
+ A clear and concise description of any alternative solutions or features you've considered.
18
+
19
+ ### Additional context
20
+
21
+ Add any other context or screenshots about the feature request here.
@@ -1,6 +1,6 @@
1
1
  # Behaviorbot config. See https://github.com/behaviorbot/ for more information.
2
2
  # Note: Please Don't edit this file directly.
3
- # Edit https://github.com/benbalter/behaviorbot-config instead.
3
+ # Edit https://github.com/benbalter/shared-community-files instead.
4
4
 
5
5
  # Configuration for update-docs - https://github.com/behaviorbot/update-docs
6
6
  updateDocsComment: "Thanks for the pull request! If you are making any changes to the user-facing functionality, please be sure to update the documentation in the `README` or `docs/` folder alongside your change. :heart:"
@@ -18,3 +18,6 @@ newPRWelcomeComment: Welcome! Congrats on your first pull request to Jekyll Avat
18
18
 
19
19
  # Configuration for first-pr-merge - https://github.com/behaviorbot/first-pr-merge
20
20
  firstPRMergeComment: "Congrats on getting your first pull request to Jekyll Avatar merged! Without amazing humans like you submitting pull requests, we couldn’t run this project. You rock! :tada:<br /><br />If you're interested in tackling another bug or feature, take a look at [the open issues](https://github.com/benbalter/jekyll-avatar/issues), especially those [labeled `help wanted`](https://github.com/benbalter/jekyll-avatar/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22)."
21
+
22
+ # Bug workaround
23
+ contact_links: []
@@ -0,0 +1 @@
1
+ patreon: benbalter
@@ -1,4 +1,6 @@
1
1
  # Configuration for probot-no-response - https://github.com/probot/no-response
2
+ # Note: Please Don't edit this file directly.
3
+ # Edit https://github.com/benbalter/shared-community-files instead.
2
4
 
3
5
  # Number of days of inactivity before an Issue is closed for lack of response
4
6
  daysUntilClose: 14
@@ -0,0 +1,4 @@
1
+ template: |
2
+ ## What's Changed
3
+
4
+ $CHANGES
@@ -1,4 +1,6 @@
1
1
  # Repository settings set via https://github.com/probot/settings
2
+ # Note: Please Don't edit this file directly.
3
+ # Edit https://github.com/benbalter/shared-community-files instead.
2
4
 
3
5
  repository:
4
6
  has_issues: true
@@ -1,4 +1,6 @@
1
1
  # Configuration for probot-stale - https://github.com/probot/stale
2
+ # Note: Please Don't edit this file directly.
3
+ # Edit https://github.com/benbalter/shared-community-files instead.
2
4
 
3
5
  # Number of days of inactivity before an Issue or Pull Request becomes stale
4
6
  daysUntilStale: 60
@@ -1,7 +1,10 @@
1
+ inherit_from: .rubocop_todo.yml
2
+
3
+ require: rubocop-jekyll
1
4
  inherit_gem:
2
- jekyll: .rubocop.yml
5
+ rubocop-jekyll: .rubocop.yml
3
6
 
4
- Style/FileName:
7
+ Naming/FileName:
5
8
  Enabled: false
6
9
 
7
10
  Metrics/LineLength:
@@ -0,0 +1,46 @@
1
+ # This configuration was generated by
2
+ # `rubocop --auto-gen-config`
3
+ # on 2019-04-18 23:25:25 +0530 using RuboCop version 0.66.0.
4
+ # The point is for the user to remove these configuration records
5
+ # one by one as the offenses are removed from the code base.
6
+ # Note that changes in the inspected code, or installation of new
7
+ # versions of RuboCop, may require this file to be generated again.
8
+
9
+ # Offense count: 1
10
+ # Cop supports --auto-correct.
11
+ # Configuration parameters: EnforcedStyle.
12
+ # SupportedStyles: auto_detection, squiggly, active_support, powerpack, unindent
13
+ Layout/IndentHeredoc:
14
+ Exclude:
15
+ - 'spec/jekyll/avatar_spec.rb'
16
+
17
+ # Offense count: 2
18
+ # Cop supports --auto-correct.
19
+ # Configuration parameters: EnforcedStyle.
20
+ # SupportedStyles: braces, no_braces, context_dependent
21
+ Style/BracesAroundHashParameters:
22
+ Exclude:
23
+ - 'spec/jekyll/avatar_spec.rb'
24
+ - 'spec/spec_helper.rb'
25
+
26
+ # Offense count: 2
27
+ # Cop supports --auto-correct.
28
+ Style/ExpandPathArguments:
29
+ Exclude:
30
+ - 'jekyll-avatar.gemspec'
31
+ - 'spec/spec_helper.rb'
32
+
33
+ # Offense count: 1
34
+ # Cop supports --auto-correct.
35
+ Style/RedundantFreeze:
36
+ Exclude:
37
+ - 'lib/jekyll-avatar/version.rb'
38
+
39
+ # Offense count: 6
40
+ # Cop supports --auto-correct.
41
+ # Configuration parameters: EnforcedStyleForMultiline.
42
+ # SupportedStylesForMultiline: comma, consistent_comma, no_comma
43
+ Style/TrailingCommaInHashLiteral:
44
+ Exclude:
45
+ - 'lib/jekyll-avatar.rb'
46
+ - 'spec/jekyll/avatar_spec.rb'
@@ -1 +1 @@
1
- 2.3.1
1
+ 2.5.3
@@ -1,7 +1,9 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 2.3.0
4
- before_install: gem install bundler -v 1.11.2
5
- sudo: false
3
+ - 2.4
6
4
  cache: bundler
7
5
  script: script/cibuild
6
+ env:
7
+ matrix:
8
+ - JEKYLL_VERSION="~> 3.0"
9
+ - JEKYLL_VERSION=">= 4.0.0.pre.alpha1"
data/Gemfile CHANGED
@@ -2,5 +2,6 @@
2
2
 
3
3
  source "https://rubygems.org"
4
4
 
5
- # Specify your gem's dependencies in jekyll-avatar.gemspec
6
5
  gemspec
6
+
7
+ gem "jekyll", ENV["JEKYLL_VERSION"] if ENV["JEKYLL_VERSION"]
data/README.md CHANGED
@@ -17,9 +17,10 @@ gem 'jekyll-avatar'
17
17
  And add the following to your site's `_config.yml` file:
18
18
 
19
19
  ```yaml
20
- gems:
20
+ plugins:
21
21
  - jekyll-avatar
22
22
  ```
23
+ Note: If you are using a Jekyll version less than 3.5.0, use the `gems` key instead of `plugins`.
23
24
 
24
25
  ## Usage
25
26
 
@@ -60,7 +61,7 @@ That will output:
60
61
  You can also pass the username as a variable, like this:
61
62
 
62
63
  ```
63
- {% assign username="hubot" %}
64
+ {% assign user="hubot" %}
64
65
  {% avatar {{ username }} %}
65
66
  ```
66
67
 
@@ -0,0 +1,3 @@
1
+ # Security Policy
2
+
3
+ To report a security vulnerability, please email [ben@balter.com](mailto:ben@balter.com).
@@ -20,10 +20,10 @@ Gem::Specification.new do |spec|
20
20
 
21
21
  spec.require_paths = ["lib"]
22
22
 
23
- spec.add_dependency "jekyll", "~> 3.0"
24
- spec.add_development_dependency "bundler", "~> 1.11"
25
- spec.add_development_dependency "rake", "~> 10.0"
23
+ spec.add_dependency "jekyll", ">= 3.0", "< 5.0"
24
+ spec.add_development_dependency "bundler", "> 1.0", "< 3.0"
25
+ spec.add_development_dependency "rake", "~> 12.3"
26
26
  spec.add_development_dependency "rspec", "~> 3.0"
27
27
  spec.add_development_dependency "rspec-html-matchers", "~> 0.9"
28
- spec.add_development_dependency "rubocop", "~> 0.50", "< 0.53"
28
+ spec.add_development_dependency "rubocop-jekyll", "~> 0.10.0"
29
29
  end
@@ -30,7 +30,7 @@ module Jekyll
30
30
  :alt => username,
31
31
  :width => size,
32
32
  :height => size,
33
- "data-proofer-ignore" => true,
33
+ "data-proofer-ignore" => true
34
34
  }
35
35
 
36
36
  if lazy_load?
@@ -72,15 +72,20 @@ module Jekyll
72
72
  end
73
73
 
74
74
  def host
75
- if ENV["PAGES_AVATARS_URL"].to_s.empty?
76
- "https://avatars#{server_number}.githubusercontent.com"
77
- else
75
+ if ENV["PAGES_AVATARS_URL"].is_a?(String) && !ENV["PAGES_AVATARS_URL"].empty?
78
76
  ENV["PAGES_AVATARS_URL"]
77
+ else
78
+ "https://avatars#{server_number}.githubusercontent.com"
79
79
  end
80
80
  end
81
81
 
82
+ def parsed_host
83
+ @parsed_host ||= {}
84
+ @parsed_host[host] ||= Addressable::URI.parse(host)
85
+ end
86
+
82
87
  def url(scale = 1)
83
- uri = Addressable::URI.parse host
88
+ uri = parsed_host
84
89
  uri.path << "/" unless uri.path.end_with?("/")
85
90
  uri = uri.join path(scale)
86
91
  uri.to_s
@@ -3,6 +3,6 @@
3
3
  module Liquid; class Tag; end; end
4
4
  module Jekyll
5
5
  class Avatar < Liquid::Tag
6
- VERSION = "0.6.0".freeze
6
+ VERSION = "0.7.0".freeze
7
7
  end
8
8
  end
metadata CHANGED
@@ -1,57 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-avatar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Balter
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-04-03 00:00:00.000000000 Z
11
+ date: 2019-08-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '3.0'
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '5.0'
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
25
28
  - !ruby/object:Gem::Version
26
29
  version: '3.0'
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '5.0'
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: bundler
29
35
  requirement: !ruby/object:Gem::Requirement
30
36
  requirements:
31
- - - "~>"
37
+ - - ">"
38
+ - !ruby/object:Gem::Version
39
+ version: '1.0'
40
+ - - "<"
32
41
  - !ruby/object:Gem::Version
33
- version: '1.11'
42
+ version: '3.0'
34
43
  type: :development
35
44
  prerelease: false
36
45
  version_requirements: !ruby/object:Gem::Requirement
37
46
  requirements:
38
- - - "~>"
47
+ - - ">"
39
48
  - !ruby/object:Gem::Version
40
- version: '1.11'
49
+ version: '1.0'
50
+ - - "<"
51
+ - !ruby/object:Gem::Version
52
+ version: '3.0'
41
53
  - !ruby/object:Gem::Dependency
42
54
  name: rake
43
55
  requirement: !ruby/object:Gem::Requirement
44
56
  requirements:
45
57
  - - "~>"
46
58
  - !ruby/object:Gem::Version
47
- version: '10.0'
59
+ version: '12.3'
48
60
  type: :development
49
61
  prerelease: false
50
62
  version_requirements: !ruby/object:Gem::Requirement
51
63
  requirements:
52
64
  - - "~>"
53
65
  - !ruby/object:Gem::Version
54
- version: '10.0'
66
+ version: '12.3'
55
67
  - !ruby/object:Gem::Dependency
56
68
  name: rspec
57
69
  requirement: !ruby/object:Gem::Requirement
@@ -81,25 +93,19 @@ dependencies:
81
93
  - !ruby/object:Gem::Version
82
94
  version: '0.9'
83
95
  - !ruby/object:Gem::Dependency
84
- name: rubocop
96
+ name: rubocop-jekyll
85
97
  requirement: !ruby/object:Gem::Requirement
86
98
  requirements:
87
99
  - - "~>"
88
100
  - !ruby/object:Gem::Version
89
- version: '0.50'
90
- - - "<"
91
- - !ruby/object:Gem::Version
92
- version: '0.53'
101
+ version: 0.10.0
93
102
  type: :development
94
103
  prerelease: false
95
104
  version_requirements: !ruby/object:Gem::Requirement
96
105
  requirements:
97
106
  - - "~>"
98
107
  - !ruby/object:Gem::Version
99
- version: '0.50'
100
- - - "<"
101
- - !ruby/object:Gem::Version
102
- version: '0.53'
108
+ version: 0.10.0
103
109
  description:
104
110
  email:
105
111
  - ben.balter@github.com
@@ -108,13 +114,18 @@ extensions: []
108
114
  extra_rdoc_files: []
109
115
  files:
110
116
  - ".github/CODEOWNERS"
117
+ - ".github/ISSUE_TEMPLATE/bug_report.md"
118
+ - ".github/ISSUE_TEMPLATE/feature_request.md"
111
119
  - ".github/config.yml"
120
+ - ".github/funding.yml"
112
121
  - ".github/no-response.yml"
122
+ - ".github/release-drafter.yml"
113
123
  - ".github/settings.yml"
114
124
  - ".github/stale.yml"
115
125
  - ".gitignore"
116
126
  - ".rspec"
117
127
  - ".rubocop.yml"
128
+ - ".rubocop_todo.yml"
118
129
  - ".ruby-version"
119
130
  - ".travis.yml"
120
131
  - Gemfile
@@ -123,6 +134,7 @@ files:
123
134
  - Rakefile
124
135
  - docs/CODE_OF_CONDUCT.md
125
136
  - docs/CONTRIBUTING.md
137
+ - docs/SECURITY.md
126
138
  - jekyll-avatar.gemspec
127
139
  - lib/jekyll-avatar.rb
128
140
  - lib/jekyll-avatar/version.rb
@@ -147,8 +159,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
147
159
  - !ruby/object:Gem::Version
148
160
  version: '0'
149
161
  requirements: []
150
- rubyforge_project:
151
- rubygems_version: 2.5.1
162
+ rubygems_version: 3.0.4
152
163
  signing_key:
153
164
  specification_version: 4
154
165
  summary: A Jekyll plugin for rendering GitHub avatars