jekyll-polyglot 1.4.0 → 1.4.1

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: 37bbf459ea94dd1edd9fbef3aeb136db17a68b78b58a1b983d8bbc2cbe24727b
4
- data.tar.gz: 5148941f48e63247596579130b8dbd8c407be7e326a2cc59b98725291d9f564d
3
+ metadata.gz: 44004d45f57d6cd3d029fb2dd11aa4636a003648e88cbb8c0af96707379143ea
4
+ data.tar.gz: 944467976c70ec60171b5c8e9717d13ac844be691ab315d7937aa827eb9d42de
5
5
  SHA512:
6
- metadata.gz: 303584c6688bf73fb8fc15a8c6bb160b0ae2b055744bdac4a3515455343a20dfbccff2d5713e74f2dca6235f0ed40e0b5d9a7f230a9a57f4b007ae2b0bd5fc8b
7
- data.tar.gz: de6caa20d33315f63c8f7f6da8800e83aa2f77548a8d21ed8bf4e8c7529d16ee96813eaef4d46fc9885867c03ae3b48e9681af041fda8c21e645ed8fbf560aaa
6
+ metadata.gz: 381ec1f760288a9945c0a353b3b1cdc5ba7bcbc14a6f6b261e23d28ae6007b25770814d2b14deb8daec986271211f9b822429135449de3974b6c71041807c344
7
+ data.tar.gz: 8a39f63b3b72670d561299308940a76f24008d73ca84411272776767beee24c2d8a1b5dce02f99d5a490635ec8ddfaa11b0ce390a203073cc283bf13c73e378a
data/README.md CHANGED
@@ -27,14 +27,14 @@ In your `_config.yml` file, add the following preferences
27
27
  ```YAML
28
28
  languages: ["en", "sv", "de", "fr"]
29
29
  default_lang: "en"
30
- exclude_from_localization: ["javascript", "images", "css", "README.md"]
30
+ exclude_from_localization: ["javascript", "images", "css", "public"]
31
31
  parallel_localization: true
32
32
  ```
33
33
  These configuration preferences indicate
34
34
  - what i18n languages you wish to support
35
35
  - what is your default "fallback" language for your content
36
36
  - what root level files/folders are excluded from localization, based
37
- on if their paths start with any of the excluded regexp substrings
37
+ on if their paths start with any of the excluded regexp substrings. (this is different than the jekyll `exclude: [README.md, CNAME]` ; you should `exclude` files and directories in your repo you dont want in your built site at all, and `exclude_from_localization` files and directories in your built site, but not in your sublanguage sites.)
38
38
  - whether to run language processing in parallel or serial
39
39
 
40
40
  The optional `lang_from_path: true` option enables getting page
@@ -199,17 +199,19 @@ sass:
199
199
 
200
200
  ## Contributions
201
201
  Please! I need all the support I can get! 🙏
202
+
202
203
  But for real I would appreciate any contributions and support. This started as an open-source side-project and has gotten bigger than I'd ever imagine!
203
204
  If you have something you'd like to contribute to jekyll-polyglot, please open a PR!
204
205
 
206
+
205
207
  ## Roadmap
206
- [ ] - **site language**: portuguese `pt_BR` `pt_PT`
207
- [ ] - **site language**: arabic `ar`
208
- [ ] - **site language**: japanese `ja`
209
- [ ] - **site language**: russian `ru`
210
- [ ] - **site language**: korean `ko`
211
- [ ] - **site language**: hebrew `he`
212
- [ ] - get whitelisted as an official github-pages jekyll plugin
208
+ * [ ] - **site language**: portuguese `pt_BR` `pt_PT`
209
+ * [ ] - **site language**: arabic `ar`
210
+ * [ ] - **site language**: japanese `ja`
211
+ * [x] - **site language**: russian `ru`
212
+ * [ ] - **site language**: korean `ko`
213
+ * [ ] - **site language**: hebrew `he`
214
+ * [ ] - get whitelisted as an official github-pages jekyll plugin
213
215
 
214
216
  ## Copyright
215
217
  Copyright (c) Samuel Volin 2021. License: MIT
@@ -15,7 +15,7 @@ module Jekyll
15
15
  site_url = @url.empty? ? site.config['url'] : @url
16
16
  i18n = "<meta http-equiv=\"Content-Language\" content=\"#{site.active_lang}\">\n"
17
17
  i18n += "<link rel=\"alternate\" hreflang=\"#{site.default_lang}\" "\
18
- "href=\" #{site_url}#{permalink}\"/>\n"
18
+ "href=\"#{site_url}#{permalink}\"/>\n"
19
19
  site.languages.each do |lang|
20
20
  next if lang == site.default_lang
21
21
 
@@ -201,7 +201,7 @@ module Jekyll
201
201
  end
202
202
  end
203
203
  start = disabled ? 'ferh' : 'href'
204
- %r{#{start}=\"?#{url}#{@baseurl}\/((?:#{regex}[^,'\"\s\/?\.#]+\.?)*(?:\/[^\]\[\)\(\"\'\s]*)?)\"}
204
+ %r{(?<!hreflang="#{@default_lang}" )#{start}=\"?#{url}#{@baseurl}\/((?:#{regex}[^,'\"\s\/?\.#]+\.?)*(?:\/[^\]\[\)\(\"\'\s]*)?)\"}
205
205
  end
206
206
 
207
207
  def relativize_urls(doc, regex)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-polyglot
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Volin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-02-07 00:00:00.000000000 Z
11
+ date: 2021-04-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -64,7 +64,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
64
64
  - !ruby/object:Gem::Version
65
65
  version: 2.7.0
66
66
  requirements: []
67
- rubygems_version: 3.2.7
67
+ rubyforge_project:
68
+ rubygems_version: 2.7.6
68
69
  signing_key:
69
70
  specification_version: 4
70
71
  summary: I18n plugin for Jekyll Blogs