coursegen 0.9.7 → 0.9.8

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: cdca83c6fc2baa1071353729e9ac19f85fe246d323c8edbeeac392e5b6e75220
4
- data.tar.gz: 71ae4a3e7491aa469232ef8737e3f88971d6fada2dc401484c50cc43e94d90c6
3
+ metadata.gz: 6e795fda87f36793e17eacef4c0f6215b71c737acd921470f7328e311738f5b2
4
+ data.tar.gz: 657d2df1548654f5fb29ada51658878ac5eb87e056a42c8bfd96fda31952c783
5
5
  SHA512:
6
- metadata.gz: 8ad815270ea969845109ddab42a91c800c02192c72d14ca10fad1476349645ff7170ec73d5df480890d1e02454faccd926029f253808345b6234e726d37b8ef6
7
- data.tar.gz: b91650dc566ccbe34adef4bbbdb7144d77d782537652538e596c6436eb2b4024e5b5489d04f8d1549899921747efc51ad817c906c610e35cbf49171a251cc72a
6
+ metadata.gz: 03a0a6ed44e0e53ad19fdd2709123efb44527f2d2928365db32f518b59971ffddbb7079f442786677ae54a4f86fc686a452b2930a14841db2fd829e00ac752d2
7
+ data.tar.gz: d3596fcd8741f91ea19b2ffcfb4c428665740ac956e9e33b12a64819421dd86c7088081bfec792ffb13a4687a021d0ef743a0c06ed6ac7db010972bf8d3f5ca6
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- coursegen (0.9.7)
4
+ coursegen (0.9.8)
5
5
  activesupport
6
6
  adsf
7
7
  byebug
data/lib/coursegen.rb CHANGED
@@ -27,6 +27,8 @@ require 'coursegen/course/lib/ical_adaptor'
27
27
  require 'coursegen/course/helpers/list_of'
28
28
  require 'coursegen/course/helpers/ical_feed_helpers'
29
29
  require 'coursegen/course/lib/helpers_'
30
+ require 'coursegen/course/lib/nanoc_filters.rb'
31
+
30
32
 
31
33
  # Coursegen is a course curriculum site generator based on nanoc, with
32
34
  # support for sections, lectures, code examples, homeworks, course
@@ -2,7 +2,7 @@ module VisualHelpers
2
2
 
3
3
  def end_of_lecture(type=:thatsall)
4
4
  if (type == :thatsall)
5
- %(<hr/><%= include_image "/content/topics/images/thatsallfolks.jpg" %>)
5
+ %(<slide_break></slide_break><hr/><%= include_image "/content/topics/images/thatsallfolks.jpg" %>)
6
6
  end
7
7
  end
8
8
  end
@@ -9,4 +9,4 @@ include FormattingHelpers
9
9
  include VisualHelpers
10
10
  include Nanoc::Helpers::Rendering
11
11
  include Nanoc::Helpers::LinkTo
12
- include Nanoc::Helpers::Tagging
12
+ include Nanoc::Helpers::Tagging
@@ -0,0 +1,9 @@
1
+ include VisualHelpers
2
+
3
+ Nanoc::Filter.define(:handle_shortcodes) do |content, _params = {}|
4
+ content
5
+ .gsub(/^\$\$INCLUDE_TOPIC :(\w+)$/) { "<%= include_topic( :#{$1}) %>" }
6
+ .gsub(/^\$\$SLIDE_TITLE (.+)$/) { "<slide_break></slide_break>\n\n### #{$1}" }
7
+ .gsub(/^\$\$SLIDE_BREAK$/) { "<slide_break></slide_break>" }
8
+ .gsub(/^\$\$END_OF_LECTURE$/) { end_of_lecture }
9
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Coursegen
4
- VERSION = '0.9.7'
4
+ VERSION = '0.9.8'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: coursegen
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.7
4
+ version: 0.9.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pito Salas
@@ -273,6 +273,7 @@ files:
273
273
  - lib/coursegen/course/helpers/visual_helpers.rb
274
274
  - lib/coursegen/course/lib/helpers_.rb
275
275
  - lib/coursegen/course/lib/ical_adaptor.rb
276
+ - lib/coursegen/course/lib/nanoc_filters.rb
276
277
  - lib/coursegen/course/lib/search_data_generator.rb
277
278
  - lib/coursegen/course/schedule/schedule_def.rb
278
279
  - lib/coursegen/course/schedule/schedule_feed.rb