jekyll-google_search_console_verification_file 1.0.1 → 1.2.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
2
  SHA256:
3
- metadata.gz: bf327c8f9a6b4b1d211c14f8db2aa48af23c6c1bdbbabab4a66a9e7bb36227ff
4
- data.tar.gz: 7d489613d1476185481149da3b46a8f3a374b46419c3d7e662eb229347552db0
3
+ metadata.gz: 2c64e1a6b83c3b89935a3dd03f655915bcde2071d26ef52f022823b7305e4213
4
+ data.tar.gz: fb4a48d1c6ad47b2ed9238133e35b8224949583d127d0a15d6d8bd6c61ce785b
5
5
  SHA512:
6
- metadata.gz: 227e8df2496e287e49e27be79606d2f7e48167a75cf2b73d965994c91d88bcae5619e1713832223796e3d313e491dddc92ee937dcc659b118e74e6cac4d44d35
7
- data.tar.gz: 359491da6c149dd6c464f5db3d75aa4b5e55a828623f3fccd57fe1d741ac1ff6228349dde67460379025741005e96470db266530c51e7455e9f096d02ff502a7
6
+ metadata.gz: f93823d4857a3f41674f0566add8a5629c1328cf9a502ea8653eca6bd3e3d19b5149c6b56a3533114f4ffa0a40872d587fd26372b7e3288a491affd819739cbb
7
+ data.tar.gz: d382cbc30fe9fba74fdafdcc01640d69124e32e631ca7e4321f889fbde5430703da216911db165f854c31b7af979cbf3dc414a819ae7bda954343d0e8d7970e2
@@ -0,0 +1,3 @@
1
+ {
2
+ "postCreateCommand": "bash scripts/devcontainer_postCreateCommand.sh"
3
+ }
@@ -1,5 +1,6 @@
1
1
  # Reference: https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
2
2
  # Validation: https://dependabot.com/docs/config-file/validator/
3
+
3
4
  version: 2
4
5
  updates:
5
6
  - package-ecosystem: "bundler"
@@ -0,0 +1,30 @@
1
+ name: Continuous Deployment # Well, semi-continuous
2
+
3
+ on:
4
+ push:
5
+ tags: v[0-9]+.[0-9]+.[0-9]+
6
+ env:
7
+ RUBY_VER: 3.0.1
8
+ jobs:
9
+ test:
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - uses: actions/checkout@v2
13
+ - name: Set up Ruby
14
+ uses: ruby/setup-ruby@v1
15
+ with:
16
+ ruby-version: ${{ env.RUBY_VER }}
17
+ bundler-cache: true
18
+ - name: Run CI Build with Rake
19
+ run: bundle exec rake
20
+ release-github:
21
+ needs: [test]
22
+ runs-on: ubuntu-latest
23
+ steps:
24
+ - uses: actions/checkout@v2
25
+ - name: Build and publish gem to GitHub Packages
26
+ if: contains(github.ref, 'refs/tags/v')
27
+ uses: jstastny/publish-gem-to-github@master
28
+ with:
29
+ token: ${{ github.token }}
30
+ owner: ${{ github.repository_owner }}
@@ -0,0 +1,51 @@
1
+ name: Continuous Integration
2
+
3
+ on:
4
+ workflow_dispatch:
5
+ push:
6
+ branches: main
7
+ pull_request:
8
+ branches: main
9
+
10
+ # OIDC permissions for qlty
11
+ permissions:
12
+ contents: read
13
+ id-token: write # IMPORTANT
14
+
15
+ jobs:
16
+ test:
17
+ runs-on: ubuntu-latest
18
+
19
+ strategy:
20
+ matrix:
21
+ ruby: [2.7.0, 3.0.1]
22
+ gemfile:
23
+ - gemfiles/jekyll_3.7.x.gemfile
24
+ - gemfiles/jekyll_4.x.x.gemfile
25
+
26
+ env:
27
+ BUNDLE_GEMFILE: ${{ matrix.gemfile }}
28
+ #CC_TEST_REPORTER_ID: 9a84a9f695de3b120b6fcead4e089b45420f7518fb2123dc5424f862d381c4ff
29
+
30
+ steps:
31
+ - name: Checkout code
32
+ uses: actions/checkout@v4
33
+
34
+ - name: Set up Ruby
35
+ uses: ruby/setup-ruby@v1
36
+ with:
37
+ ruby-version: ${{ matrix.ruby }}
38
+ bundler-cache: true
39
+ bundler: 2.2.18
40
+
41
+ - name: Run tests
42
+ run: bundle exec rake spec
43
+
44
+ - name: Run linting
45
+ run: bundle exec rake rubocop
46
+
47
+ - uses: qltysh/qlty-action/coverage@v2
48
+ with:
49
+ oidc: true
50
+ format: simplecov
51
+ files: coverage/.resultset.json
@@ -0,0 +1,37 @@
1
+ name: "CodeQL"
2
+
3
+ on:
4
+ push:
5
+ branches: [ main ]
6
+ pull_request:
7
+ # The branches below must be a subset of the branches above
8
+ branches: [ main ]
9
+ schedule:
10
+ - cron: '41 19 1 * *'
11
+
12
+ jobs:
13
+ analyze:
14
+ name: Analyze
15
+ runs-on: ubuntu-latest
16
+ permissions:
17
+ actions: read
18
+ contents: read
19
+ security-events: write
20
+
21
+ strategy:
22
+ fail-fast: false
23
+ matrix:
24
+ language: [ 'ruby' ]
25
+
26
+ steps:
27
+ - name: Checkout repository
28
+ uses: actions/checkout@v2
29
+
30
+ # Initializes the CodeQL tools for scanning.
31
+ - name: Initialize CodeQL
32
+ uses: github/codeql-action/init@v1
33
+ with:
34
+ languages: ${{ matrix.language }}
35
+
36
+ - name: Perform CodeQL Analysis
37
+ uses: github/codeql-action/analyze@v1
data/.gitignore CHANGED
@@ -8,7 +8,7 @@ gemfiles/Gemfile*.lock
8
8
  # Bundle local config
9
9
  .bundle/
10
10
 
11
- # Package gem from ($rake install)
11
+ # Package gem from $(rake install)
12
12
  pkg/
13
13
 
14
14
  # simplecov
@@ -19,3 +19,6 @@ coverage/
19
19
  .rspec_status
20
20
  spec/dest/
21
21
  spec/reports/
22
+
23
+ # Jekyll - when switching from gh-pages-source branch
24
+ _site/
data/.qlty/.gitignore ADDED
@@ -0,0 +1,7 @@
1
+ *
2
+ !configs
3
+ !configs/**
4
+ !hooks
5
+ !hooks/**
6
+ !qlty.toml
7
+ !.gitignore
@@ -0,0 +1 @@
1
+ source-path=SCRIPTDIR
data/.qlty/qlty.toml ADDED
@@ -0,0 +1,85 @@
1
+ # This file was automatically generated by `qlty init`.
2
+ # You can modify it to suit your needs.
3
+ # We recommend you to commit this file to your repository.
4
+ #
5
+ # This configuration is used by both Qlty CLI and Qlty Cloud.
6
+ #
7
+ # Qlty CLI -- Code quality toolkit for developers
8
+ # Qlty Cloud -- Fully automated Code Health Platform
9
+ #
10
+ # Try Qlty Cloud: https://qlty.sh
11
+ #
12
+ # For a guide to configuration, visit https://qlty.sh/d/config
13
+ # Or for a full reference, visit https://qlty.sh/d/qlty-toml
14
+ config_version = "0"
15
+
16
+ exclude_patterns = [
17
+ "*_min.*",
18
+ "*-min.*",
19
+ "*.min.*",
20
+ "**/.yarn/**",
21
+ "**/*.d.ts",
22
+ "**/assets/**",
23
+ "**/bower_components/**",
24
+ "**/build/**",
25
+ "**/cache/**",
26
+ "**/config/**",
27
+ "**/db/**",
28
+ "**/deps/**",
29
+ "**/dist/**",
30
+ "**/extern/**",
31
+ "**/external/**",
32
+ "**/generated/**",
33
+ "**/Godeps/**",
34
+ "**/gradlew/**",
35
+ "**/mvnw/**",
36
+ "**/node_modules/**",
37
+ "**/protos/**",
38
+ "**/seed/**",
39
+ "**/target/**",
40
+ "**/templates/**",
41
+ "**/testdata/**",
42
+ "**/vendor/**",
43
+ ]
44
+
45
+ test_patterns = [
46
+ "**/test/**",
47
+ "**/spec/**",
48
+ "**/*.test.*",
49
+ "**/*.spec.*",
50
+ "**/*_test.*",
51
+ "**/*_spec.*",
52
+ "**/test_*.*",
53
+ "**/spec_*.*",
54
+ ]
55
+
56
+ [smells]
57
+ mode = "comment"
58
+
59
+ [smells.boolean_logic]
60
+ threshold = 4
61
+
62
+ [smells.file_complexity]
63
+ threshold = 55
64
+
65
+ [smells.return_statements]
66
+ threshold = 4
67
+
68
+ [smells.nested_control_flow]
69
+ threshold = 4
70
+
71
+ [smells.function_parameters]
72
+ threshold = 4
73
+
74
+ [smells.function_complexity]
75
+ threshold = 5
76
+
77
+ [[source]]
78
+ name = "default"
79
+ default = true
80
+
81
+ [[plugin]]
82
+ name = "rubocop"
83
+ version = "1.81.6"
84
+ package_file = "Gemfile"
85
+ package_filters = ["rubocop"]
data/.rubocop.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  # See pages relaed at https://docs.rubocop.org/rubocop/1.12/cops_layout.html
2
2
 
3
- # Rubocop extensions
4
- require:
3
+ # Rubocop plugins
4
+ plugins:
5
5
  - rubocop-rake
6
6
  - rubocop-rspec
7
7
 
@@ -15,11 +15,14 @@ AllCops:
15
15
  - lib/**/*.rb
16
16
  - spec/**/*.rb
17
17
  Exclude:
18
- # Travis: during build there will be a lot of rubocop config files in this pat which will cause build failure as the refer to gems which are not installed by this project.
18
+ # Travis: during build there will be a lot of rubocop config files in this path which will cause build failure as the refer to gems which are not installed by this project.
19
19
  # See https://github.com/rubocop/rubocop/issues/9832
20
20
  - gemfiles/vendor/bundle/**/*
21
+ NewCops: disable
21
22
 
22
- Gemspec/DateAssignment:
23
+ Gemspec/DeprecatedAttributeAssignment:
24
+ Enabled: true
25
+ Gemspec/RequireMFA:
23
26
  Enabled: true
24
27
 
25
28
  Layout/LineEndStringConcatenationIndentation:
@@ -67,6 +70,16 @@ Lint/UnreachableCode:
67
70
  Severity: error
68
71
  Lint/UselessAccessModifier:
69
72
  Enabled: false
73
+ Lint/AmbiguousOperatorPrecedence:
74
+ Enabled: true
75
+ Lint/AmbiguousRange:
76
+ Enabled: true
77
+ Lint/IncompatibleIoSelectWithFiberScheduler:
78
+ Enabled: true
79
+ Lint/RequireRelativeSelfPath:
80
+ Enabled: true
81
+ Lint/UselessRuby2Keywords:
82
+ Enabled: true
70
83
 
71
84
  Metrics/BlockLength:
72
85
  Enabled: true
@@ -78,6 +91,11 @@ Naming/FileName:
78
91
  - lib/jekyll-google_search_console_verification_file.rb
79
92
  Naming/InclusiveLanguage:
80
93
  Enabled: true
94
+ Naming/BlockForwarding:
95
+ Enabled: true
96
+
97
+ Security/IoMethods:
98
+ Enabled: true
81
99
 
82
100
  Style/ArgumentsForwarding:
83
101
  Enabled: true
@@ -115,6 +133,22 @@ Style/StringLiteralsInInterpolation:
115
133
  EnforcedStyle: double_quotes
116
134
  Style/SwapValues:
117
135
  Enabled: true
136
+ Style/FileRead:
137
+ Enabled: true
138
+ Style/FileWrite:
139
+ Enabled: true
140
+ Style/MapToHash:
141
+ Enabled: true
142
+ Style/NumberedParameters:
143
+ Enabled: true
144
+ Style/NumberedParametersLimit:
145
+ Enabled: true
146
+ Style/OpenStructUse:
147
+ Enabled: true
148
+ Style/RedundantSelfAssignmentBranch:
149
+ Enabled: true
150
+ Style/SelectByRegexp:
151
+ Enabled: true
118
152
 
119
153
 
120
154
  # Reference: https://github.com/rubocop/rubocop-rake/blob/master/config/default.yml
@@ -126,12 +160,17 @@ Rake:
126
160
  # https://github.com/rubocop/rubocop-rspec/blob/master/config/default.yml
127
161
  RSpec:
128
162
  Enabled: true
129
- RSpec/FilePath:
163
+ RSpec/SpecFilePathFormat:
164
+ # Disable to match structure of lib/. For jekyll plugin inclusion convention features, not having lib/jekyll/sth.rb but lib/jekyll-sth.rb
165
+ Enabled: false
166
+ RSpec/SpecFilePathSuffix:
130
167
  # Disable to match structure of lib/. For jekyll plugin inclusion convention features, not having lib/jekyll/sth.rb but lib/jekyll-sth.rb
131
168
  Enabled: false
132
169
  RSpec/IdenticalEqualityAssertion:
133
170
  Enabled: true
134
- RSpec/Rails/AvoidSetupHook:
135
- Enabled: false
136
171
  RSpec/BeforeAfterAll:
137
172
  Enabled: false
173
+ RSpec/ExcessiveDocstringSpacing:
174
+ Enabled: true
175
+ RSpec/SubjectDeclaration:
176
+ Enabled: true
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 3.0.1
1
+ 3.1.0
data/.simplecov CHANGED
@@ -1,6 +1,7 @@
1
1
  # vi: ft=ruby
2
2
 
3
3
  SimpleCov.start do
4
- enable_coverage :branch # Add branch coverage statistics.
5
- minimum_coverage 90 # Minimum coverage percentage.
4
+ enable_coverage :branch # Add branch coverage statistics.
5
+ minimum_coverage 90 # Minimum coverage percentage.
6
+ command_name "test:bdd" # Must be set for codeclimat reporter
6
7
  end
data/Appraisals CHANGED
@@ -1,4 +1,4 @@
1
- # Override jekyll verion from .gemspec
1
+ # Override jekyll version from .gemspec
2
2
 
3
3
  appraise "jekyll-3.7.x" do
4
4
  gem "jekyll", "~> 3.7"
data/CHANGELOG.md CHANGED
@@ -1,10 +1,26 @@
1
+ # Changelog
2
+ All notable changes to this project will be documented in this file.
3
+
4
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
+
7
+ ## [Unreleased]
8
+
9
+ ## [1.1.0] - 2025-10-29
10
+ ### Changed
11
+ - Updated format of this file.
12
+ - Bump ruby to 3.0.2 from 3.0.1.
13
+ - Migrated CI from Travis to GitHub Actions.
14
+
1
15
  ## [1.0.1] - 2021-08-18
2
- - Fix gemspec dependency range stynax
16
+ ### Fixed
17
+ - Fix gemspec dependency range stynax.
3
18
 
4
19
  ## [1.0.0] - 2021-07-04
5
20
  - No changes from `v0.2.0` but just bumping to final first major release version!
6
21
 
7
22
  ## [0.2.0] - 2021-07-04
23
+ ### Added
8
24
  - Using the `gem-release` gem extension to make release process easier.
9
25
 
10
26
  ## [0.1.0] - 2021-07-04
data/CONTRIBUTING.md CHANGED
@@ -1,4 +1,4 @@
1
1
  # How to contribute
2
2
  Please use GitHub tooling (issues, PRs) to disucssion and code contributions!
3
3
 
4
- When you open an PR, Travis will build your code, run tests, liters and so on.
4
+ When you open an PR, GitHub Actions will build your code, run tests, liters and so on.
data/Gemfile CHANGED
@@ -16,13 +16,12 @@ group :development, :test do
16
16
  gem "gem-release", "~> 2.0", require: false
17
17
  gem "rake", "~> 13.0", require: false
18
18
  gem "solargraph", require: false
19
- gem "travis", "~> 1.0", require: false
20
19
  end
21
20
 
22
21
  group :test do
23
22
  gem "rspec", "~> 3.0"
24
23
  gem "rubocop", "~> 1.18", require: false
25
24
  gem "rubocop-rake", "~> 0.6", require: false
26
- gem "rubocop-rspec", "~> 2.4", require: false
25
+ gem "rubocop-rspec", "~> 3.5", require: false
27
26
  gem "simplecov", "~> 0.21"
28
27
  end
data/OSSMETADATA ADDED
@@ -0,0 +1 @@
1
+ osslifecycle=active
data/README.md CHANGED
@@ -1,14 +1,27 @@
1
- # Jekyll Google Search Console Verification File Generator Plugin
1
+ # Jekyll Google Search Console Verification File Generator Plugin [![Post on X](https://img.shields.io/twitter/url/http/shields.io.svg?style=social)](https://x.com/intent/tweet?text=Generate%20a%20Google%20Search%20Console%20verification%20file%20for%20your%20Jekyll%20site%20with%20this%20plugin&url=https://github.com/erikw/jekyll-google_search_console_verification_file&via=erik_westrup&hashtags=jekyll,plugin)
2
2
  [![Gem Version](https://badge.fury.io/rb/jekyll-google_search_console_verification_file.svg)](https://badge.fury.io/rb/jekyll-google_search_console_verification_file)
3
- [![Gem Downloads](https://ruby-gem-downloads-badge.herokuapp.com/jekyll-google_search_console_verification_file?color=brightgreen&type=total&label=gem%20downloads)](https://rubygems.org/gems/jekyll-google_search_console_verification_file)
4
- [![Travis Build Status](https://img.shields.io/travis/erikw/jekyll-google_search_console_verification_file/main?logo=travis)](https://travis-ci.com/erikw/jekyll-google_search_console_verification_file)
5
- [![Code Climate Maintainability](https://api.codeclimate.com/v1/badges/59050f3f66ed1f1ee32e/maintainability)](https://codeclimate.com/github/erikw/jekyll-google_search_console_verification_file/maintainability)
6
- [![Code Climate Test Coverage](https://api.codeclimate.com/v1/badges/59050f3f66ed1f1ee32e/test_coverage)](https://codeclimate.com/github/erikw/jekyll-google_search_console_verification_file/test_coverage)
3
+ [![Gem Downloads](https://img.shields.io/gem/dt/jekyll-google_search_console_verification_file?label=gem%20downloads)](https://rubygems.org/gems/jekyll-google_search_console_verification_file)
4
+ [![Continuous Integration](https://github.com/erikw/jekyll-google_search_console_verification_file/actions/workflows/ci.yml/badge.svg)](https://github.com/erikw/jekyll-google_search_console_verification_file/actions/workflows/ci.yml)
5
+ [![Continuous Deployment](https://github.com/erikw/jekyll-google_search_console_verification_file/actions/workflows/cd.yml/badge.svg)](https://github.com/erikw/jekyll-google_search_console_verification_file/actions/workflows/cd.yml)
6
+ [![CodeQL](https://github.com/erikw/jekyll-google_search_console_verification_file/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/erikw/jekyll-google_search_console_verification_file/actions/workflows/codeql-analysis.yml)
7
+ [![Code Climate Maintainability](https://qlty.sh/gh/erikw/projects/jekyll-google_search_console_verification_file/maintainability)](https://qlty.sh/gh/erikw/projects/jekyll-google_search_console_verification_file)
8
+ [![Code Climate Test Coverage](https://qlty.sh/gh/erikw/projects/jekyll-google_search_console_verification_file/test_coverage)](https://qlty.sh/gh/erikw/projects/jekyll-google_search_console_verification_file)
9
+ [![SLOC](https://sloc.xyz/github/erikw/jekyll-google_search_console_verification_file?lower=true)](#)
10
+ [![Number of programming languages used](https://img.shields.io/github/languages/count/erikw/jekyll-google_search_console_verification_file)](#)
11
+ [![Top programming languages used](https://img.shields.io/github/languages/top/erikw/jekyll-google_search_console_verification_file)](#)
12
+ [![License](https://img.shields.io/github/license/erikw/jekyll-google_search_console_verification_file)](LICENSE.txt)
13
+ [![OSS Lifecycle](https://img.shields.io/osslifecycle/erikw/jekyll-google_search_console_verification_file)](https://github.com/Netflix/osstracker)
7
14
 
15
+ <p align="center">
16
+ <!-- Ref: https://dev.to/azure/adding-a-github-codespace-button-to-your-readme-5f6l -->
17
+ <a href="https://github.com/codespaces/new?hide_repo_select=true&ref=main&repo=381051146" title="Open in GitHub Codespaces" ><img alt="Open in GitHub Codespaces" src="https://github.com/codespaces/badge.svg"></a>
18
+ </p>
8
19
 
20
+ > [!TIP]
21
+ > :point_right: **Live demo**: https://erikw.github.io/jekyll-google_search_console_verification_file/
9
22
 
10
23
 
11
- This is a very simple plugin that will generate a Google Search Console (GSC from here) [verification file](https://support.google.com/webmasters/answer/9008080?hl=en) to your `_site/` directory in a Jekyll project. This file is used by GSC to verify that you own the site and looks for example like my [googlef47733b3288357e4.html](https://erikw.me/google47733b3288357e4.html).
24
+ This is a very simple plugin that will generate a Google Search Console (GSC from here on) [verification file](https://support.google.com/webmasters/answer/9008080?hl=en) to your `_site/` directory in a Jekyll project. This file is used by GSC to verify that you own the site and looks for example like my [googlef47733b3288357e4.html](https://erikw.me/google47733b3288357e4.html).
12
25
 
13
26
  ## Why?
14
27
  Why use this plugin?
@@ -19,39 +32,45 @@ Why use this plugin?
19
32
 
20
33
 
21
34
  ### !TL;DidRead
22
- There are multiple ways to [verify](https://support.google.com/webmasters/answer/9008080?hl=en) the ownership of your site. The two simpler ways, both suitable for Github Pages owners, are to add an `<meta> tag to your pages` or upload a special unique file to the root of the site. For adding the meta tag, there are excellent plugins making this very easy for example [jekyll-seo-tag](http://jekyll.github.io/jekyll-seo-tag/usage/). If you want to the meta tag, I recommend this plugin.
35
+ There are multiple ways to [verify](https://support.google.com/webmasters/answer/9008080?hl=en) the ownership of your site. The two simpler ways, both suitable for GitHub Pages owners, are to add a `<meta> tag to your pages` or upload a special, unique file to the root of the site. For adding the meta tag, there are excellent plugins making this very easy, for example [jekyll-seo-tag](http://jekyll.github.io/jekyll-seo-tag/usage/). If you want the meta tag, I recommend this plugin.
23
36
 
24
- However if you feel that it's bloated to add this `<meta>` tag to the header all you pages, keeping file size and page load speed in mind, you may one to go for the file based verification method instead.
37
+ However, if you feel that it's bloated to add this `<meta>` tag to the header of all your pages, keeping file size and page load speed in mind, you may one to go for the file-based verification method instead.
25
38
 
26
- So with the file based method, why not just add the file you downloaded from GSC to your source directory and let Jekyll put it in `_site/` on generation? As we're using a SSG (Static Site Generator), we should generate everything we can. It's verdantly nice to keep the source tree clean and make everything that can be a configuration that generates what is needed.
39
+ So with the file-based method, why not just add the file you downloaded from GSC to your source directory and let Jekyll put it in `_site/` on generation? As we're using an SSG (Static Site Generator), we should generate everything we can. It's very nice to keep the source tree clean and make everything that can be a configuration that generates what is needed.
27
40
 
28
- Thus, this plugin exist to solve this problem. Give the plugin the unique code GSC provided you and it will generate the file for you in `_site/`!
41
+ Thus, this plugin exists to solve this problem. Give the plugin the unique code GSC provided you, and it will generate the file for you in `_site/`!
29
42
 
30
43
  Note that if you do place a verification file in the root of the source tree, this will override the generation by this plugin.
31
44
 
32
45
  # Installation
33
- 1. Add this gem to your Jekyll site's Gemfile
34
- - Simply with `$ bundle add jekyll-google-search-console-verification-file` when standing in the Jekyll project
35
- - Or manually by adding to `Gemfile`
46
+ 1. Add this gem to your Jekyll site's Gemfile in the `:jekyll_plugins` group:
47
+ * On CLI (in project root directory):
48
+ ```shell
49
+ bundle add --group jekyll_plugins jekyll-google_search_console_verification_file
50
+ ```
51
+ * Or manually:
36
52
  ```ruby
37
- gem 'jekyll-google-search-console-verification-file'
53
+ group :jekyll_plugins do
54
+ [...]
55
+ gem 'jekyll-google_search_console_verification_file'
56
+ end
38
57
  ```
39
- and then running `$ bundle install`.
58
+ 1. Run `$ bundle install`.
40
59
  1. In your site's `_config.yml`, enable the plugin:
41
60
  ```yml
42
61
  plugins:
43
- - jekyll-google-search-console-verification-file
62
+ - jekyll-google_search_console_verification_file
44
63
  ```
45
- 1. Get the GSC unique code for you website.
64
+ 1. Get the GSC unique code for your website.
46
65
  1. Register your website at [Google Search Console](https://search.google.com/search-console?resource_id=https://erikw.me/)
47
66
  1. From the main dashboard of your site at GSC: _Settings > Ownership Verification > HTML File_ and download the unique file
48
- 1. Instead of putting this file in our jekyll site, just copy the unique code from the HTML file name e.g. from `googlef47733b3288357e4.html` copy `f47733b3288357e4`.
67
+ 1. Instead of putting this file in our Jekyll site, just copy the unique code from the HTML file name, e.g., from `googlef47733b3288357e4.html`, copy `f47733b3288357e4`.
49
68
  1. In your site's `_config.yml`, configure this plugin with the code from the previous step:
50
69
  ```yml
51
70
  google_search_console:
52
71
  verification_file_code: 47733b3288357e4
53
72
  ```
54
- 1. Now just build your site and verify that the verification file now exist!
73
+ 1. Now, just build your site and verify that the verification file now exists!
55
74
  ```console
56
75
  $ bundle exec jekyll build
57
76
  $ ls _site/ | grep "google.*\.html"
@@ -59,19 +78,19 @@ Note that if you do place a verification file in the root of the source tree, th
59
78
  ```
60
79
 
61
80
  # Development
62
- The structure of this plugin was inspired by [https://ayastreb.me/writing-a-jekyll-plugin/](https://ayastreb.me/writing-a-jekyll-plugin/), the plugin jekyll-sitemap and the [Bundler Gem tutorial](https://bundler.io/guides/creating_gem.html).
81
+ The structure of this plugin was inspired by [https://ayastreb.me/writing-a-jekyll-plugin/](https://ayastreb.me/writing-a-jekyll-plugin/), the plugin jekyll-sitemap, and the [Bundler Gem tutorial](https://bundler.io/guides/creating_gem.html).
63
82
 
64
83
  After checking out the repo;
65
- 1. Install [RVM](https://rvm.io/rvm/install) and install a supported ruby version (see .gemspec)
66
- 1. run `script/setup` to install dependencies
67
- 1. run `script/test` to run the tests
68
- 1. You can also run `script/console` for an interactive prompt that will allow you to experiment.
84
+ 1. Install [RVM](https://rvm.io/rvm/install) and install a supported Ruby version (see .gemspec)
85
+ 1. run `scripts/setup` to install dependencies
86
+ 1. run `scripts/test` to run the tests
87
+ 1. You can also run `scripts/console` for an interactive prompt that will allow you to experiment.
69
88
 
70
89
  To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
71
90
 
72
91
 
73
92
  ## Local development
74
- Following the setup at [how-to-specify-local-ruby-gems-in-your-gemfile](https://rossta.net/blog/how-to-specify-local-ruby-gems-in-your-gemfile.html), these are the steps needed to build a jekyll site with a local clone of this plugin for local testing.
93
+ Following the setup at [how-to-specify-local-ruby-gems-in-your-gemfile](https://rossta.net/blog/how-to-specify-local-ruby-gems-in-your-gemfile.html), these are the steps needed to build a Jekyll site with a local clone of this plugin for local testing.
75
94
 
76
95
  1. Clone this repo to your machine, say at `~/src/jekyll-google_search_console_verification_file`
77
96
  1. In your Jekyll project's `Gemfile`:
@@ -80,76 +99,54 @@ Following the setup at [how-to-specify-local-ruby-gems-in-your-gemfile](https://
80
99
  1. Configure bundler to use a local path for this gem in this project:
81
100
  - `$ bundle config --local local.jekyll-google_search_console_verification_file ~/src/jekyll-google_search_console_verification_file`
82
101
  1. Update the project: `$ bundle install`
83
- 1. Now the project will build with the local clone of this plugin when issuing e.g. `bundle exec jekyll build`
102
+ 1. Now the project will build with the local clone of this plugin when issuing e.g., `bundle exec jekyll build`
84
103
  1. When you're done:
85
104
  - Remove the local override with: `$ bundle config --delete local.jekyll-google_search_console_verification_file`
86
- - Optionally restore the original gem include in `Gemfile` or keep building from a branch in the github repo.
105
+ - Optionally restore the original gem included in `Gemfile` or keep building from a branch in the GitHub repo.
87
106
 
88
107
  ## Releasing
89
- Instructions for releasing on rubygems.org below. Optionally make a GitHub [release](https://github.com/erikw/jekyll-google_search_console_verification_file/releases) after this for the pushed git tag.
108
+ Instructions for releasing on rubygems.org are below. Optionally make a GitHub [release](https://github.com/erikw/jekyll-google_search_console_verification_file/releases) after this for the pushed git tag.
90
109
 
91
- ## Using bundler/gem_tasks rake tasks
110
+ ## [manual] Using bundler/gem_tasks rake tasks
92
111
  Following instructions from [bundler.io](https://bundler.io/guides/creating_gem.html#releasing-the-gem):
93
- ```console
94
- $ vi -p lib/jekyll-google_search_console_verification_file/version.rb CHANGELOG.md
95
- $ bundle exec rake build
96
- $ ver=$(ruby -r jekyll-google_search_console_verification_file/version -e 'puts Jekyll::GoogleSearchConsoleVerificationFile::VERSION')
112
+ ```shell
113
+ vi -p lib/jekyll-google_search_console_verification_file/version.rb CHANGELOG.md
114
+ bundle exec rake build
115
+ ver=$(ruby -r jekyll-google_search_console_verification_file/version -e 'puts Jekyll::GoogleSearchConsoleVerificationFile::VERSION')
97
116
 
98
117
  # Optional: test locally by including in another project
99
- $ gem install pkg/jekyll-google_search_console_verification_file-$ver.gem
118
+ gem install pkg/jekyll-google_search_console_verification_file-$ver.gem
100
119
 
101
- $ bundle exec rake release
120
+ bundle exec rake release
102
121
  ```
103
122
 
104
- ## Using gem-release gem extension
123
+ ## [recommended] Using gem-release gem extension
105
124
  Using [gem-release](https://github.com/svenfuchs/gem-release):
106
- ```console
107
- $ vi CHANGELOG.md && git add CHANGELOG.md && git commit -m "Update CHANGELOG.md" && git push
108
- $ gem bump --version minor --tag --sign --push --release
125
+ ```shell
126
+ vi CHANGELOG.md && git add CHANGELOG.md && git commit -m "Update CHANGELOG.md" && git push
127
+ gem signin
128
+ gem bump --version minor --tag --push --release --sign
109
129
  ```
110
130
  For `--version`, use `major|minor|patch` as needed.
111
131
 
112
132
  ## Multi-versions
113
- * For ruby, just use RVM to switch between supported ruby version specified in `.gemspec`.
133
+ * For Ruby, just use RVM to switch between supported Ruby versions specified in `.gemspec`.
114
134
  * To run with different jekyll versions, [Appraisal](https://github.com/thoughtbot/appraisal) is used with [`Appraisals`](Appraisals) to generate different [`gemfiles/`](gemfiles/)
115
135
  - To use a specific Gemfile, run like
116
- ```console
117
- $ BUNDLE_GEMFILE=gemfiles/jekyll_4.x.x.gemfile bundle exec rake spec
118
- $ bundle exec appraisal jekyll-4.x.x rake spec
136
+ ```shell
137
+ BUNDLE_GEMFILE=gemfiles/jekyll_4.x.x.gemfile bundle exec rake spec
138
+ bundle exec appraisal jekyll-4.x.x rake spec
119
139
  ```
120
140
  - To run `rake spec` for all gemfiles:
121
- ```console
122
- $ bundle exec appraisal rake spec
141
+ ```shell
142
+ bundle exec appraisal rake spec
123
143
  ```
124
144
  - To generate new/updated gemfiles from `Appraisals`
125
- ```console
126
- $ bundle exec appraisal install
127
- $ bundle exec appraisal generate --travis
145
+ ```shell
146
+ bundle exec appraisal install
147
+ bundle exec appraisal generate
128
148
  ```
129
149
 
130
- ## Travis
131
- To use the [travis cli client](https://github.com/travis-ci/travis.rb) (installed from `Gemfile`):
132
- 1. Get a GitHub OAuth token by
133
- - going to [github.com/settings/tokens](https://github.com/settings/tokens)
134
- - create a new token named `travis-cli`
135
- - Set the scopes `repo`, `read:org`, `user:email` according to the [docs](https://docs.travis-ci.com/user/github-oauth-scopes).
136
- 1. Set travis.com as the default so we don't need to add `--pro` to most commands
137
- ```console
138
- $ bundle exec travis endpoint --set-default --api-endpoint https://api.travis-ci.com/
139
- ```
140
- 1. Login with the cli client
141
- ```console
142
- $ bundle exec travis login --github-token $GITHUB_TOKEN
143
- ```
144
- 1. Now the cli client can be used (might need `--pro` to use travis.com)
145
- ```console
146
- $ bundle exec travis lint
147
- $ bundle exec travis accounts
148
- $ bundle exec travis status
149
- $ bundle exec travis branches
150
- $ bundle exec travis monitor
151
- ```
152
-
153
150
  # Contributing
154
151
  Bug reports and pull requests are welcome on GitHub at https://github.com/erikw/jekyll-google_search_console_verification_file.
155
152
 
data/Rakefile CHANGED
@@ -13,7 +13,14 @@ RSpec::Core::RakeTask.new(:spec)
13
13
  require "rubocop/rake_task"
14
14
  RuboCop::RakeTask.new(:rubocop) do |t|
15
15
  # See https://docs.rubocop.org/rubocop/usage/basic_usage.html
16
- t.options = ['--display-cop-names', '--parallel']
16
+ t.options = ["--display-cop-names", "--parallel"]
17
+ end
18
+
19
+ desc "Run Qlty code analysis"
20
+ task :qlty do
21
+ sh "qlty smells --all"
22
+ sh "qlty metrics --all --max-depth=2 --sort complexity --limit 10"
23
+ # sh "qlty lint" # Just runs rubocop, not necessary as we have a task for this already
17
24
  end
18
25
 
19
26
  # default task: Add spec and rubocop to default tasks.
@@ -7,16 +7,17 @@ gem "kramdown", "2.3.1"
7
7
  gem "kramdown-parser-gfm", "~> 1.0"
8
8
 
9
9
  group :development, :test do
10
- gem "rake", "~> 13.0", require: false
11
- gem "travis", "~> 1.0", require: false
12
10
  gem "appraisal", "~> 2.4", require: false
11
+ gem "gem-release", "~> 2.0", require: false
12
+ gem "rake", "~> 13.0", require: false
13
+ gem "solargraph", require: false
13
14
  end
14
15
 
15
16
  group :test do
16
17
  gem "rspec", "~> 3.0"
17
18
  gem "rubocop", "~> 1.18", require: false
18
19
  gem "rubocop-rake", "~> 0.6", require: false
19
- gem "rubocop-rspec", "~> 2.4", require: false
20
+ gem "rubocop-rspec", "~> 3.5", require: false
20
21
  gem "simplecov", "~> 0.21"
21
22
  end
22
23
 
@@ -5,16 +5,17 @@ source "https://rubygems.org"
5
5
  gem "jekyll", "~> 4.0"
6
6
 
7
7
  group :development, :test do
8
- gem "rake", "~> 13.0", require: false
9
- gem "travis", "~> 1.0", require: false
10
8
  gem "appraisal", "~> 2.4", require: false
9
+ gem "gem-release", "~> 2.0", require: false
10
+ gem "rake", "~> 13.0", require: false
11
+ gem "solargraph", require: false
11
12
  end
12
13
 
13
14
  group :test do
14
15
  gem "rspec", "~> 3.0"
15
16
  gem "rubocop", "~> 1.18", require: false
16
17
  gem "rubocop-rake", "~> 0.6", require: false
17
- gem "rubocop-rspec", "~> 2.4", require: false
18
+ gem "rubocop-rspec", "~> 3.5", require: false
18
19
  gem "simplecov", "~> 0.21"
19
20
  end
20
21
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Jekyll
4
4
  module GoogleSearchConsoleVerificationFile
5
- VERSION = "1.0.1"
5
+ VERSION = "1.2.0"
6
6
  end
7
7
  end
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ # Devcontainer postCreateCommand.
3
+ # Install dependencies for running this project in GitHub Codespaces.
4
+
5
+ set -eux
6
+
7
+ # For project.
8
+ bundle install
@@ -6,3 +6,7 @@ set -vx
6
6
  rvm install ruby-$(cat .ruby-version)
7
7
  gem install bundler -v 2.2.18
8
8
  bundle install
9
+
10
+
11
+ # Qlty CLI tool. Ref: https://docs.qlty.sh/cli/quickstart
12
+ curl https://qlty.sh | sh
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-google_search_console_verification_file
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Erik Westrup
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-08-18 00:00:00.000000000 Z
11
+ date: 2025-10-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -41,20 +41,26 @@ extensions: []
41
41
  extra_rdoc_files: []
42
42
  files:
43
43
  - ".ackrc"
44
- - ".codeclimate.yml"
44
+ - ".devcontainer/devcontainer.json"
45
45
  - ".editorconfig"
46
46
  - ".github/dependabot.yml"
47
+ - ".github/workflows/cd.yml"
48
+ - ".github/workflows/ci.yml"
49
+ - ".github/workflows/codeql-analysis.yml"
47
50
  - ".gitignore"
51
+ - ".qlty/.gitignore"
52
+ - ".qlty/configs/.shellcheckrc"
53
+ - ".qlty/qlty.toml"
48
54
  - ".rspec"
49
55
  - ".rubocop.yml"
50
56
  - ".ruby-version"
51
57
  - ".simplecov"
52
- - ".travis.yml"
53
58
  - Appraisals
54
59
  - CHANGELOG.md
55
60
  - CONTRIBUTING.md
56
61
  - Gemfile
57
62
  - LICENSE.txt
63
+ - OSSMETADATA
58
64
  - README.md
59
65
  - Rakefile
60
66
  - SECURITY.md
@@ -66,11 +72,12 @@ files:
66
72
  - lib/jekyll-google_search_console_verification_file/generator.rb
67
73
  - lib/jekyll-google_search_console_verification_file/template.html
68
74
  - lib/jekyll-google_search_console_verification_file/version.rb
69
- - script/build
70
- - script/console
71
- - script/lint
72
- - script/setup
73
- - script/test
75
+ - scripts/build
76
+ - scripts/console
77
+ - scripts/devcontainer_postCreateCommand.sh
78
+ - scripts/lint
79
+ - scripts/setup
80
+ - scripts/test
74
81
  homepage: https://github.com/erikw/jekyll-google_search_console_verification_file/
75
82
  licenses:
76
83
  - MIT
@@ -96,7 +103,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
96
103
  - !ruby/object:Gem::Version
97
104
  version: '0'
98
105
  requirements: []
99
- rubygems_version: 3.2.15
106
+ rubygems_version: 3.3.3
100
107
  signing_key:
101
108
  specification_version: 4
102
109
  summary: Generate a Google Search Console verification file from your _config.yml
data/.codeclimate.yml DELETED
@@ -1,24 +0,0 @@
1
- # Reference: https://docs.codeclimate.com/docs/advanced-configuration#section-checks
2
- # Reference of plugins: https://docs.codeclimate.com/docs/list-of-engines
3
-
4
- version: "2"
5
- plugins:
6
- rubocop:
7
- enabled: true
8
- channel: rubocop-1-18-3
9
- fixme:
10
- enabled: true
11
- eslint:
12
- enabled: true
13
- duplication:
14
- enabled: true
15
- config:
16
- languages:
17
- - ruby
18
- - javascript
19
- ratings:
20
- paths:
21
- - "**.rb"
22
- - "**.js"
23
- exclude_paths:
24
- - script/
data/.travis.yml DELETED
@@ -1,30 +0,0 @@
1
- # NOTE run $(travis lint) after modyifing this file.
2
-
3
- # Travis
4
- # - build lifecycle: https://docs.travis-ci.com/user/job-lifecycle
5
- # - config doc: https://config.travis-ci.com/
6
- # - ruby defaults: https://docs.travis-ci.com/user/languages/ruby/
7
- # Codeclimate setup: https://docs.codeclimate.com/docs/travis-ci-test-coverage
8
-
9
- version: ~> 1.0
10
- env:
11
- global:
12
- - CC_TEST_REPORTER_ID=9a84a9f695de3b120b6fcead4e089b45420f7518fb2123dc5424f862d381c4ff
13
- language: ruby
14
- # Buid matrix (rvm x gemfile = 2x2) with one version from each supported major version in range defined in .gemspec for
15
- rvm:
16
- - 2.7.0
17
- - 3.0.1
18
- gemfile:
19
- - gemfiles/jekyll_3.7.x.gemfile
20
- - gemfiles/jekyll_4.x.x.gemfile
21
- cache: bundler
22
- before_install: gem install bundler -v 2.2.18
23
- #install: bundle install # Default
24
- before_script:
25
- - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
26
- - chmod +x ./cc-test-reporter
27
- - ./cc-test-reporter before-build
28
- #script: bundle exec rake # Default
29
- after_script:
30
- - ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
File without changes
File without changes
File without changes
File without changes