You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by Sam Ruby <ru...@apache.org> on 2016/01/22 03:40:51 UTC
[whimsy.git] [2/50] Commit ac14172: Rake spec now works
Commit ac141728c362e244eb8f59b4cdd9dce42cff2fa6:
Rake spec now works
Branch: refs/heads/master
Author: Sam Ruby <ru...@intertwingly.net>
Committer: Sam Ruby <ru...@intertwingly.net>
Pusher: rubys <ru...@apache.org>
------------------------------------------------------------
.gitignore | ++
Rakefile | +
main.rb | -----
------------------------------------------------------------
8 changes: 3 additions, 5 deletions.
------------------------------------------------------------
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..3459ee8
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,2 @@
+public/assets
+test/work
diff --git a/Rakefile b/Rakefile
index bd71f1b..1c58b8c 100644
--- a/Rakefile
+++ b/Rakefile
@@ -1,6 +1,7 @@
require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:spec)
task :default => :spec
+task :spec => :work
file 'test/work' do
mkdir_p 'test/work'
diff --git a/main.rb b/main.rb
index 7b180a9..b133516 100755
--- a/main.rb
+++ b/main.rb
@@ -13,8 +13,6 @@
require 'ruby2js/filter/require'
require 'yaml'
-require 'net/http'
-require_relative 'helpers/string'
if ENV['RACK_ENV'] == 'test'
FOUNDATION_BOARD = 'test/work/board'
@@ -24,9 +22,6 @@
MINUTES_WORK = '/var/tools/data'
end
-require_relative 'model/pending'
-require_relative 'model/draft'
-
get '/' do
agenda = Dir.chdir(FOUNDATION_BOARD) {Dir['board_agenda_*.txt'].sort.last}
redirect to("/#{agenda[/\d+_\d+_\d+/].gsub('_', '-')}/")