Skip to content

Commit

Permalink
Merge commit 'alex/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
schacon committed Mar 8, 2008
2 parents a9118c0 + d32d06a commit 535e37f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 23 deletions.
7 changes: 4 additions & 3 deletions TODO
@@ -1,6 +1,5 @@
= SOON
* fix duplication of routes/methods to accommodate file extensions
* working launchd plist
* repo stats/info/maintenance page
* deleting pages
* pushing repo

Expand All @@ -15,12 +14,14 @@
* users (email/name/ip - use for commits)

= LATER/MAYBE
* repo stats/info/maintenance page
* backlinks (trivial syntax, ideally)
* outliner functionality
* menubar item launcher (like Instiki back in the day)
* RubyCocoa GUI
* working launchd plist

= DONE
* fix duplication of routes/methods to accommodate file extensions
* "append selected text/link to page" bookmarklet (shamelessly cribbed
from Trsly/Instapaper)
* allow "code pages" by supporting file extensions, applying syntax
Expand Down
30 changes: 10 additions & 20 deletions git-wiki.rb
Expand Up @@ -71,28 +71,18 @@ def touchfile
show :history, "History of #{@page.name}"
end

get '/h/:page/:rev' do
@page = Page.new(page_with_ext, params[:rev])
show :show, "#{@page.name} / version #{params[:rev]})"
end

# FIXME this repeats the above just to accomodate pages with
# file extensions. bad!
get '/h/:page.:format/:rev' do
@page = Page.new(page_with_ext, params[:rev])
show :show, "#{@page.name} / version #{params[:rev]})"
end

get '/d/:page/:rev' do
@page = Page.new(page_with_ext)
show :delta, "Diff of #{@page.name}"
['/h/:page/:rev', '/h/:page.:format/:rev'].each do |r|
get r do
@page = Page.new(page_with_ext, params[:rev])
show :show, "#{@page.name} (version #{params[:rev]})"
end
end

# FIXME this repeats the above just to accomodate pages with
# file extensions. bad!
get '/d/:page.:format/:rev' do
@page = Page.new(page_with_ext)
show :delta, "Diff of #{@page.name}"
['/d/:page/:rev', '/d/:page.:format/:rev'].each do |r|
get r do
@page = Page.new(page_with_ext)
show :delta, "Diff of #{@page.name}"
end
end

get '/a/tarball' do
Expand Down

0 comments on commit 535e37f

Please sign in to comment.