jekyll-scholar 6.3.2 → 6.3.3

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: aea0dbf09c4b9675d2341466637d0d869ca493ae944bd4a151d62d080debada1
4
- data.tar.gz: a060e41c331f683ac52f7eaff50d42e3c50f9715e415f6326cc6fc6c1efddf6f
3
+ metadata.gz: a730e051294ecd12de18ee1c73878fa0688721a32951ca8d946340a1d576e8c0
4
+ data.tar.gz: 4abfbd1a91e5a42910c4df9c7d52e6ad6ffc0683a64102cd0fe2710324e85181
5
5
  SHA512:
6
- metadata.gz: b529c1db74c86b0fdc854725b3251463a06a18c5818cff4630ba17a5d34bf661f3a3c33bd23bcaee553cb5b9e4edbd5d9c4d602f67bd48ee4d811205c3690561
7
- data.tar.gz: 3bbef145e79ef2e5e18732ec345f94726ca97e55a040c57509dc51308f8fafdf24ab21c010570f52eeef7fbcf79248f042ed1910c6a2f81293abdee42bc44d91
6
+ metadata.gz: 6141ae4a92377c83f0d6903187354ca1f7719c3dc4361036c68b0d4543d38ac620ec7c1759ccb5a7aca8196e7fcd15f4018f608394a8614b6659df7480f453d0
7
+ data.tar.gz: 65748fe1ebf6cae81e167aa2137c52a2a88fbb35fe2829732d02f16c8dc5f1ca9f677e5bad1aaf1469ae2690919035a3fee8e9ba5407a5a19e562a534b7169ee
@@ -385,6 +385,62 @@ Feature: Details
385
385
  And the "_site/bibliography/2008/10.0000/1111/index.html" file should exist
386
386
  And the "_site/bibliography/2018/ruby/index.html" file should exist
387
387
 
388
+ @tags @details
389
+ Scenario: Detail page URLs can have custom permalinks and custom base URL (issue #284)
390
+ Given I have a configuration file with:
391
+ | key | value |
392
+ | baseurl | /blog/ |
393
+ | permalink | /:title/ |
394
+ And I have a scholar configuration with:
395
+ | key | value |
396
+ | source | ./_bibliography |
397
+ | bibliography | references |
398
+ | details_layout | details.html |
399
+ | details_permalink | /:details_dir/:year/:doi:extension |
400
+ And I have a "_bibliography" directory
401
+ And I have a file "_bibliography/references.bib":
402
+ """
403
+ @book{rubydoi,
404
+ title = {The Ruby Programming Language},
405
+ author = {Flanagan, David and Matsumoto, Yukihiro},
406
+ year = {2008},
407
+ publisher = {O'Reilly Media},
408
+ doi = {10.0000/1111}
409
+ }
410
+
411
+ @book{ruby,
412
+ title = {The Ruby Programming Language},
413
+ author = {Flanagan, David and Matsumoto, Yukihiro},
414
+ year = {2018},
415
+ publisher = {O'Reilly Media}
416
+ }
417
+ """
418
+ And I have a "_layouts" directory
419
+ And I have a file "_layouts/details.html":
420
+ """
421
+ ---
422
+ ---
423
+ <html>
424
+ <head></head>
425
+ <body>
426
+ {{ page.entry.title }}
427
+ </body>
428
+ </html>
429
+ """
430
+ And I have a page "scholar.html":
431
+ """
432
+ ---
433
+ ---
434
+ {% bibliography %}
435
+ """
436
+ When I run jekyll
437
+ Then the _site directory should exist
438
+ And the "_site/scholar/index.html" file should exist
439
+ And I should see "<a[^>]+href=\"/blog/bibliography/2008/10.0000/1111/\">" in "_site/scholar/index.html"
440
+ And I should see "<a[^>]+href=\"/blog/bibliography/2018/ruby/\">" in "_site/scholar/index.html"
441
+ And the "_site/blog/bibliography/2008/10.0000/1111/index.html" file should exist
442
+ And the "_site/blog/bibliography/2018/ruby/index.html" file should exist
443
+
388
444
  @generators @parse_months
389
445
  Scenario: Months are parsed by default
390
446
  Given I have a scholar configuration with:
@@ -641,10 +641,11 @@ module Jekyll
641
641
  end
642
642
 
643
643
  # generate the URL
644
- URL.new(
645
- :template => config['details_permalink'],
646
- :placeholders => url_placeholders
647
- ).to_s
644
+ File.join(base,
645
+ URL.new(
646
+ :template => config['details_permalink'],
647
+ :placeholders => url_placeholders
648
+ ).to_s)
648
649
  end
649
650
 
650
651
  def base_url
@@ -1,5 +1,5 @@
1
1
  module Jekyll
2
2
  class Scholar
3
- VERSION = '6.3.2'.freeze
3
+ VERSION = '6.3.3'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-scholar
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.3.2
4
+ version: 6.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sylvester Keil
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-10-29 00:00:00.000000000 Z
11
+ date: 2019-11-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll