usmu 1.3.0 → 1.4.0

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
  SHA1:
3
- metadata.gz: 278fdf99bee6cdcc7e63997b7a3e10f2e85cdc0b
4
- data.tar.gz: 24d4beb2f6fd199d8dcc76eb92dd49bf5b17244c
3
+ metadata.gz: 1c604445bb1362ae82eee81874dcac8f1554508b
4
+ data.tar.gz: 9f4631b23e2cc31dd6a417d56b9f785c96ac1c46
5
5
  SHA512:
6
- metadata.gz: 007ceabd71a6c5d26677a08e5d2a2ece75d5a7e909fdea8ad2710febfc31e2acaa12ded407fc89a5b118e70781b428e1c2b7082c3eabf75ac6f126e7cd3ce2e2
7
- data.tar.gz: 707ac6fcb658f88810ad7f8f1b3c0b897ad155578e3b58be403b7d8190eb02e5ecfea4d0b17b4d718d78d2068b17cd057adfc316734d1242a2e64680fe336680
6
+ metadata.gz: c7e79ad4f57f09adb78f65d8e81913595e784d2adbb2e96d7ab916f4ca420ba818557acb26b023a74a9f8f5d9ae6c5d4ac56c7e0640a206a55df1714034bab5a
7
+ data.tar.gz: 89a628f5f9dd4ec35b34e681430c7bbf1e2f57e376f7b8cd2c03133eda48114aa6d94bb5d961039f8d08ad5e4373f48242631724d5b5f889a25a43487873e003
data/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Usmu Change Log
2
2
 
3
+ ## 1.4.0
4
+
5
+ Matthew Scharley <matt.scharley@gmail.com>
6
+
7
+ * Fix minorly broken test (7071fbe4cc46be437154a441483bfad522e7d565)
8
+ * Permalink should include extension if wanted. (9a2cde9f2337243d7cc1965f9f08b5ee82ae6ce9)
9
+
3
10
  ## 1.3.0
4
11
 
5
12
  Matthew Scharley <matt.scharley@gmail.com>
@@ -68,11 +68,8 @@ module Usmu
68
68
 
69
69
  date = self.date
70
70
 
71
- extension = output_extension
72
- extension = '.' + extension if extension
73
-
74
71
  link_tr = link.gsub('%f', File.basename(@name[0..(@name.rindex('.') - 1)]))
75
- date.strftime(link_tr) + extension
72
+ date.strftime(link_tr)
76
73
  end
77
74
  end
78
75
  end
data/lib/usmu/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
 
2
2
  module Usmu
3
3
  # The current version string for the gem
4
- VERSION = '1.3.0'
4
+ VERSION = '1.4.0'
5
5
  end
@@ -8,6 +8,7 @@ require 'usmu/ui/rack_server'
8
8
  RSpec.describe Usmu::Plugin::Core do
9
9
  let (:plugin) { described_class.new }
10
10
  let (:configuration) { Usmu::Configuration.from_hash({}) }
11
+ let (:generator) { Usmu::SiteGenerator.new(configuration) }
11
12
  let (:ui) { OpenStruct.new configuration: configuration }
12
13
  let (:commander) { Usmu::MockCommander.new }
13
14
  let (:options) { Commander::Command::Options.new }
@@ -49,6 +50,10 @@ RSpec.describe Usmu::Plugin::Core do
49
50
  end
50
51
 
51
52
  context '#command_generate' do
53
+ before do
54
+ allow(configuration).to receive(:generator).and_return(generator)
55
+ end
56
+
52
57
  it 'raises an error when arguments are specified' do
53
58
  expect { plugin.command_generate(['foo'], options) }.to raise_error('This command does not take arguments')
54
59
  end
@@ -58,7 +63,7 @@ RSpec.describe Usmu::Plugin::Core do
58
63
  end
59
64
 
60
65
  it 'should generate a site' do
61
- expect(configuration.generator).to receive(:generate)
66
+ expect(generator).to receive(:generate)
62
67
 
63
68
  plugin.send :ui=, ui
64
69
  plugin.command_generate [], options
@@ -1,4 +1,4 @@
1
1
  ---
2
- permalink: '%Y/%m/%f'
2
+ permalink: '%Y/%m/%f.html'
3
3
  collection: posts
4
4
  layout: post
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: usmu
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthew Scharley