rack-blogengine 1.0.0 → 1.0.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
  SHA1:
3
- metadata.gz: 3b32f8e7d16332b11d2c783ccdf7b0edaf969699
4
- data.tar.gz: 4bd1ab11bb1d1d9f86f08d664bbeb55320d8dcfb
3
+ metadata.gz: 1ec3dbdaaad36d19c2a3bc37d0d61415040cec61
4
+ data.tar.gz: 41d877baa91f2ad61e5bf522eea066ba57e75054
5
5
  SHA512:
6
- metadata.gz: 850c1940379673c70fbee289bdd898dfaaf94d9d5217f79ccff12e1a8f9f94ce3e10af412f47a804e7be4902cfa64f0b56da48e166a0f7963fde310dffe2e664
7
- data.tar.gz: 84a2f53739dbc3b0c207f0e1df21c979cafaf82fe1948732af0cc35a13427c29782533390e6fad66d106d4ea1642384d3fafee13195e477e336741242372db8f
6
+ metadata.gz: f43d1c69143cce1b2ee7a077724f7a7dd7f9c66b0f6edee5947cad62846330d497eeadc30334b38b067ffa6c0ad9298d2960cd801595b58a4572dc974b754887
7
+ data.tar.gz: c0c6ca935f96d01cc9b82d50e69bc31a85d2c04140d7caaab2b0e4b5809d78e9440b27d7231f9b82d034003be2c9e41456ee37e837314cdafa8bbdc5fcac9bd5
data/.travis.yml CHANGED
@@ -11,7 +11,6 @@ rvm:
11
11
 
12
12
  matrix:
13
13
  allow_failures:
14
- - rvm: rbx
15
14
  - rvm: jruby
16
15
  - rvm: ruby-head
17
16
 
data/Gemfile CHANGED
@@ -1,4 +1,4 @@
1
1
  source 'https://rubygems.org'
2
- # gem "rubysl-test-unit", :platform => :rbx
2
+
3
3
  # Specify your gem's dependencies in rack-blogengine.gemspec
4
4
  gemspec
data/MANIFEST ADDED
@@ -0,0 +1,39 @@
1
+ .gitignore
2
+ .rubocop.yml
3
+ .travis.yml
4
+ .yardopts
5
+ Gemfile
6
+ LICENSE.txt
7
+ MANIFEST
8
+ README.md
9
+ Rakefile
10
+ assets/config.yml
11
+ assets/content_error.content
12
+ assets/date_error.content
13
+ assets/date_test.content
14
+ assets/index.content
15
+ assets/layout.html
16
+ assets/operator.content
17
+ assets/operator.rb
18
+ assets/pygment.content
19
+ assets/title_error.content
20
+ bin/rack-blogengine
21
+ lib/rack/blogengine.rb
22
+ lib/rack/blogengine/application.rb
23
+ lib/rack/blogengine/application_router.rb
24
+ lib/rack/blogengine/command_line_interface.rb
25
+ lib/rack/blogengine/document.rb
26
+ lib/rack/blogengine/document_parser.rb
27
+ lib/rack/blogengine/operator.rb
28
+ lib/rack/blogengine/version.rb
29
+ rack-blogengine.gemspec
30
+ task/default.rake
31
+ task/floodtest.rake
32
+ task/manifest.rake
33
+ task/test.rake
34
+ task/travis.rake
35
+ test/rack/blogengine/application_router_test.rb
36
+ test/rack/blogengine/application_test.rb
37
+ test/rack/blogengine/command_line_interface_test.rb
38
+ test/rack/blogengine/document_parser_test.rb
39
+ test/test_helper.rb
data/README.md CHANGED
@@ -17,7 +17,6 @@ Rack Middleware to serve a simple blog
17
17
  - ruby 2.0.0
18
18
  - ruby 2.1.0
19
19
  - ruby 2.1.1
20
- - jruby 1.7.9
21
20
 
22
21
  ## Installation
23
22
 
@@ -139,3 +138,4 @@ In your layout.html then
139
138
  5. Create new Pull Request
140
139
 
141
140
 
141
+
data/Rakefile CHANGED
@@ -1,7 +1,7 @@
1
1
  require "bundler/gem_tasks"
2
2
  require 'rake/testtask'
3
- require 'cucumber/rake/task'
3
+ # require 'cucumber/rake/task'
4
4
 
5
- Dir.glob('tasks/*.rake').each { |r| import r }
5
+ Dir.glob('task/*.rake').each { |r| import r }
6
6
 
7
7
 
data/bin/rack-blogengine CHANGED
@@ -10,7 +10,7 @@ end
10
10
  target = ARGV[1]
11
11
  target = '' unless ARGV[1]
12
12
 
13
- cli = Rack::Blogengine::CommandLineInterface.new
13
+ cli = Rack::Blogengine::CommandLineInterface
14
14
 
15
15
  if target != ''
16
16
  cli.send(command, target)
@@ -4,11 +4,12 @@ require 'yaml'
4
4
  module Rack
5
5
  module Blogengine
6
6
  #
7
- # This Class handles all cli input (running the app, generate folder skeleton)
7
+ # This Module handles all cli input (running the app, generate folder skeleton)
8
8
  #
9
9
  # @author [benny]
10
10
  #
11
- class CommandLineInterface
11
+ module CommandLineInterface
12
+ class << self
12
13
  # Handle unavailable methods
13
14
  # @param [String] name [called Methodname]
14
15
  # @param [Array] *args [Available args]
@@ -146,6 +147,7 @@ module Rack
146
147
  end
147
148
 
148
149
  private :get_config, :setup, :build_rack_app
150
+ end
149
151
  end
150
152
  end
151
153
  end
@@ -141,7 +141,7 @@ module Rack
141
141
  # Populates highlight.css with specific highlight css
142
142
  # @param [String] target [Targetfolder in which highlight.css lives]
143
143
  def self.generate_highlight_css(target)
144
- cli = Rack::Blogengine::CommandLineInterface.new
144
+ cli = Rack::Blogengine::CommandLineInterface
145
145
  system("rm #{target}/assets/style/highlight.css") if ::File.exist?("#{target}/assets/style/highlight.css")
146
146
 
147
147
  cli.send(:setup, 'highlight.css', "#{target}/assets/style", false)
@@ -7,6 +7,6 @@ module Rack
7
7
  #
8
8
  module Blogengine
9
9
  # Current Rack::Blogengine Version
10
- VERSION = '1.0.0'.freeze
10
+ VERSION = '1.0.1'.freeze
11
11
  end
12
12
  end
@@ -13,19 +13,16 @@ Gem::Specification.new do |spec|
13
13
  spec.homepage = "http://www.bennyklotz.at"
14
14
  spec.license = "MIT"
15
15
 
16
- spec.files = `git ls-files`.split($/)
16
+ spec.files = File.read(File.expand_path('../MANIFEST', __FILE__)).split("\n")
17
17
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
- spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
18
  spec.require_paths = ["lib"]
20
19
 
21
- spec.add_development_dependency "bundler", "~> 1.3"
20
+ spec.add_development_dependency "bundler", "~> 1.5"
22
21
  spec.add_development_dependency "rake"
23
- spec.add_development_dependency "cucumber"
24
- spec.add_development_dependency "capybara"
25
22
  spec.add_development_dependency "coveralls"
26
23
  spec.add_development_dependency "rack-test"
27
24
 
28
25
  spec.add_runtime_dependency "rack"
29
26
  spec.add_runtime_dependency "pygments.rb"
30
27
  spec.add_runtime_dependency "nokogiri"
31
- end
28
+ end
File without changes
@@ -0,0 +1,33 @@
1
+ test_runs = if ENV['TESTS']
2
+ Integer(ENV['TESTS'])
3
+ else
4
+ 30
5
+ end
6
+
7
+ namespace :floodtest do
8
+ task :unit do
9
+ desc 'Run Unit floodtest (default 30 tests, configurable via ENV["TESTS"])'
10
+ 1.upto(test_runs) do |i|
11
+ puts "Running test #{i} of #{test_runs}"
12
+ exit(-1) if !system('bundle exec rake test:unit')
13
+ end
14
+ end
15
+
16
+ # task :spec do
17
+ # desc 'Run Spec floodtest (default 30 tests, configurable via ENV["TESTS"])'
18
+ # 1.upto(test_runs) do |i|
19
+ # puts "Running test #{i} of #{test_runs}"
20
+ # exit(-1) if !system('bundle exec rake test:spec ')
21
+ # end
22
+ # end
23
+
24
+ # task :feature do
25
+ # desc 'Run Feature floodtest (default 30 tests, configurable via ENV["TESTS"])'
26
+ # 1.upto(test_runs) do |i|
27
+ # puts "Running test #{i} of #{test_runs}"
28
+ # exit(-1) if !system('bundle exec rake test:feature')
29
+ # end
30
+ # end
31
+ end
32
+
33
+
@@ -0,0 +1,8 @@
1
+ desc 'Generates the MANIFEST file'
2
+ task :manifest do
3
+ files = `git ls-files`.split("\n").sort
4
+ handle = File.open(File.expand_path('../../MANIFEST', __FILE__), 'w')
5
+
6
+ handle.write(files.join("\n"))
7
+ handle.close
8
+ end
data/task/test.rake ADDED
@@ -0,0 +1,19 @@
1
+ namespace :test do
2
+ Rake::TestTask.new(:unit) do |t|
3
+ t.libs << "test" << "bin" << "ext" << "controllers" << "helpers" << "models"
4
+ t.test_files = FileList['test/**/*_test.rb']
5
+ t.verbose = true
6
+ end
7
+
8
+ # Rake::TestTask.new(:spec) do |t|
9
+ # t.libs << "spec" << "bin" << "ext" << "controllers" << "helpers" << "models"
10
+ # t.test_files = FileList['spec/**/*_spec.rb']
11
+ # t.verbose = true
12
+ # end
13
+
14
+ # Cucumber::Rake::Task.new(:feature) do |t|
15
+ # t.cucumber_opts = "features --format pretty"
16
+ # end
17
+ end
18
+
19
+
File without changes
@@ -23,7 +23,7 @@ class ApplicationTest < MiniTest::Unit::TestCase
23
23
  end
24
24
 
25
25
  def setup
26
- @cli = Rack::Blogengine::CommandLineInterface.new
26
+ @cli = Rack::Blogengine::CommandLineInterface
27
27
  capture_stdout { @cli.generate(testpath) }
28
28
  Rack::Blogengine.config = @cli.send(:get_config, testpath)
29
29
  Rack::Blogengine.documents = Rack::Blogengine::DocumentParser.parse_in_documents(testpath)
@@ -7,7 +7,7 @@ require 'test_helper.rb'
7
7
  #
8
8
  class CommandLineInterfaceTest < MiniTest::Unit::TestCase
9
9
  def setup
10
- @cli = Rack::Blogengine::CommandLineInterface.new
10
+ @cli = Rack::Blogengine::CommandLineInterface
11
11
  end
12
12
 
13
13
  def test_available_methods
@@ -61,7 +61,7 @@ class CommandLineInterfaceTest < MiniTest::Unit::TestCase
61
61
  config['Usage'] = 'yes'
62
62
  config['Username'] = 'Benny'
63
63
  config['Password'] = 'Bensn'
64
-
64
+
65
65
  app = @cli.send(:build_rack_app, testpath, config)
66
66
 
67
67
  assert_instance_of(Rack::Builder, app, 'Rack app should be instance of Rack::Builder')
@@ -7,7 +7,7 @@ require 'test_helper'
7
7
  #
8
8
  class DocumentParserTest < MiniTest::Unit::TestCase
9
9
  def setup
10
- @cli = Rack::Blogengine::CommandLineInterface.new
10
+ @cli = Rack::Blogengine::CommandLineInterface
11
11
  capture_stdout { @cli.generate(testpath) }
12
12
  @cli.send(:get_config, testpath)
13
13
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-blogengine
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Benny1992
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2014-03-08 00:00:00 Z
12
+ date: 2014-03-19 00:00:00 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -18,7 +18,7 @@ dependencies:
18
18
  requirements:
19
19
  - - ~>
20
20
  - !ruby/object:Gem::Version
21
- version: "1.3"
21
+ version: "1.5"
22
22
  type: :development
23
23
  version_requirements: *id001
24
24
  - !ruby/object:Gem::Dependency
@@ -33,7 +33,7 @@ dependencies:
33
33
  type: :development
34
34
  version_requirements: *id002
35
35
  - !ruby/object:Gem::Dependency
36
- name: cucumber
36
+ name: coveralls
37
37
  prerelease: false
38
38
  requirement: &id004 !ruby/object:Gem::Requirement
39
39
  requirements:
@@ -41,7 +41,7 @@ dependencies:
41
41
  type: :development
42
42
  version_requirements: *id004
43
43
  - !ruby/object:Gem::Dependency
44
- name: capybara
44
+ name: rack-test
45
45
  prerelease: false
46
46
  requirement: &id005 !ruby/object:Gem::Requirement
47
47
  requirements:
@@ -49,45 +49,29 @@ dependencies:
49
49
  type: :development
50
50
  version_requirements: *id005
51
51
  - !ruby/object:Gem::Dependency
52
- name: coveralls
52
+ name: rack
53
53
  prerelease: false
54
54
  requirement: &id006 !ruby/object:Gem::Requirement
55
55
  requirements:
56
56
  - *id003
57
- type: :development
57
+ type: :runtime
58
58
  version_requirements: *id006
59
59
  - !ruby/object:Gem::Dependency
60
- name: rack-test
60
+ name: pygments.rb
61
61
  prerelease: false
62
62
  requirement: &id007 !ruby/object:Gem::Requirement
63
63
  requirements:
64
64
  - *id003
65
- type: :development
65
+ type: :runtime
66
66
  version_requirements: *id007
67
67
  - !ruby/object:Gem::Dependency
68
- name: rack
68
+ name: nokogiri
69
69
  prerelease: false
70
70
  requirement: &id008 !ruby/object:Gem::Requirement
71
71
  requirements:
72
72
  - *id003
73
73
  type: :runtime
74
74
  version_requirements: *id008
75
- - !ruby/object:Gem::Dependency
76
- name: pygments.rb
77
- prerelease: false
78
- requirement: &id009 !ruby/object:Gem::Requirement
79
- requirements:
80
- - *id003
81
- type: :runtime
82
- version_requirements: *id009
83
- - !ruby/object:Gem::Dependency
84
- name: nokogiri
85
- prerelease: false
86
- requirement: &id010 !ruby/object:Gem::Requirement
87
- requirements:
88
- - *id003
89
- type: :runtime
90
- version_requirements: *id010
91
75
  description: Blogengine based on rack applications
92
76
  email:
93
77
  - klotz.benjamin@yahoo.de
@@ -104,6 +88,7 @@ files:
104
88
  - .yardopts
105
89
  - Gemfile
106
90
  - LICENSE.txt
91
+ - MANIFEST
107
92
  - README.md
108
93
  - Rakefile
109
94
  - assets/config.yml
@@ -126,10 +111,11 @@ files:
126
111
  - lib/rack/blogengine/operator.rb
127
112
  - lib/rack/blogengine/version.rb
128
113
  - rack-blogengine.gemspec
129
- - tasks/default.rake
130
- - tasks/floodtest.rake
131
- - tasks/test.rake
132
- - tasks/travis.rake
114
+ - task/default.rake
115
+ - task/floodtest.rake
116
+ - task/manifest.rake
117
+ - task/test.rake
118
+ - task/travis.rake
133
119
  - test/rack/blogengine/application_router_test.rb
134
120
  - test/rack/blogengine/application_test.rb
135
121
  - test/rack/blogengine/command_line_interface_test.rb
@@ -158,10 +144,6 @@ rubygems_version: 2.2.2
158
144
  signing_key:
159
145
  specification_version: 4
160
146
  summary: Blogengine based on rack applications
161
- test_files:
162
- - test/rack/blogengine/application_router_test.rb
163
- - test/rack/blogengine/application_test.rb
164
- - test/rack/blogengine/command_line_interface_test.rb
165
- - test/rack/blogengine/document_parser_test.rb
166
- - test/test_helper.rb
147
+ test_files: []
148
+
167
149
  has_rdoc:
data/tasks/floodtest.rake DELETED
@@ -1,33 +0,0 @@
1
- test_runs = if ENV['TESTS']
2
- Integer(ENV['TESTS'])
3
- else
4
- 30
5
- end
6
-
7
- namespace :floodtest do
8
- task :unit do
9
- desc 'Run Unit floodtest (default 30 tests, configurable via ENV["TESTS"])'
10
- 1.upto(test_runs) do |i|
11
- puts "Running test #{i} of #{test_runs}"
12
- exit(-1) if !system('bundle exec rake test:unit')
13
- end
14
- end
15
-
16
- task :spec do
17
- desc 'Run Spec floodtest (default 30 tests, configurable via ENV["TESTS"])'
18
- 1.upto(test_runs) do |i|
19
- puts "Running test #{i} of #{test_runs}"
20
- exit(-1) if !system('bundle exec rake test:spec ')
21
- end
22
- end
23
-
24
- task :feature do
25
- desc 'Run Feature floodtest (default 30 tests, configurable via ENV["TESTS"])'
26
- 1.upto(test_runs) do |i|
27
- puts "Running test #{i} of #{test_runs}"
28
- exit(-1) if !system('bundle exec rake test:feature')
29
- end
30
- end
31
- end
32
-
33
-
data/tasks/test.rake DELETED
@@ -1,19 +0,0 @@
1
- namespace :test do
2
- Rake::TestTask.new(:unit) do |t|
3
- t.libs << "test" << "bin" << "ext" << "controllers" << "helpers" << "models"
4
- t.test_files = FileList['test/**/*_test.rb']
5
- t.verbose = true
6
- end
7
-
8
- Rake::TestTask.new(:spec) do |t|
9
- t.libs << "spec" << "bin" << "ext" << "controllers" << "helpers" << "models"
10
- t.test_files = FileList['spec/**/*_spec.rb']
11
- t.verbose = true
12
- end
13
-
14
- Cucumber::Rake::Task.new(:feature) do |t|
15
- t.cucumber_opts = "features --format pretty"
16
- end
17
- end
18
-
19
-