dolt 0.22.0 → 0.23.0
Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile.lock
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
dolt (0.
|
4
|
+
dolt (0.23.0)
|
5
5
|
json (~> 1.5)
|
6
|
-
libdolt (~> 0.
|
6
|
+
libdolt (~> 0.23)
|
7
7
|
sinatra (~> 1.0)
|
8
8
|
thin (~> 1.4)
|
9
9
|
tiltout (~> 1.4)
|
@@ -16,13 +16,13 @@ GEM
|
|
16
16
|
eventmachine (1.0.3)
|
17
17
|
github-markup (0.7.5)
|
18
18
|
htmlentities (4.3.1)
|
19
|
-
json (1.
|
20
|
-
libdolt (0.
|
19
|
+
json (1.8.0)
|
20
|
+
libdolt (0.23.0)
|
21
21
|
htmlentities (~> 4.3)
|
22
22
|
json (~> 1.7)
|
23
23
|
makeup (~> 0.2)
|
24
24
|
mime-types (~> 1.19)
|
25
|
-
rugged (= 0.
|
25
|
+
rugged (= 0.18.0.gh.de28323)
|
26
26
|
tzinfo (~> 0.3)
|
27
27
|
makeup (0.3.0)
|
28
28
|
github-markup (~> 0.7)
|
@@ -40,7 +40,7 @@ GEM
|
|
40
40
|
rack-test (0.6.2)
|
41
41
|
rack (>= 1.0)
|
42
42
|
rake (0.9.6)
|
43
|
-
rugged (0.
|
43
|
+
rugged (0.18.0.gh.de28323)
|
44
44
|
sinatra (1.4.3)
|
45
45
|
rack (~> 1.4)
|
46
46
|
rack-protection (~> 1.4)
|
data/dolt.gemspec
CHANGED
@@ -11,7 +11,7 @@ end
|
|
11
11
|
|
12
12
|
Gem::Specification.new do |s|
|
13
13
|
s.name = "dolt"
|
14
|
-
s.version = "0.
|
14
|
+
s.version = "0.23.0"
|
15
15
|
s.authors = ["Christian Johansen"]
|
16
16
|
s.email = ["christian@gitorious.org"]
|
17
17
|
s.homepage = "http://gitorious.org/gitorious/dolt"
|
@@ -20,7 +20,7 @@ Gem::Specification.new do |s|
|
|
20
20
|
|
21
21
|
s.rubyforge_project = "dolt"
|
22
22
|
|
23
|
-
s.add_dependency "libdolt", "~>0.
|
23
|
+
s.add_dependency "libdolt", "~>0.23"
|
24
24
|
s.add_dependency "thin", "~>1.4"
|
25
25
|
s.add_dependency "sinatra", "~>1.0"
|
26
26
|
s.add_dependency "tiltout", "~>1.4"
|
data/lib/dolt/sinatra/actions.rb
CHANGED
@@ -29,6 +29,9 @@ module Dolt
|
|
29
29
|
end
|
30
30
|
|
31
31
|
def render_error(error, repo, ref)
|
32
|
+
if error.class.to_s == "Rugged::ReferenceError" && ref == "HEAD"
|
33
|
+
return body(renderer.render("empty", { :repository => repo, :ref => ref }))
|
34
|
+
end
|
32
35
|
template = error.class.to_s == "Rugged::IndexerError" ? :"404" : :"500"
|
33
36
|
add_headers(response)
|
34
37
|
body(renderer.render(template, {
|
@@ -35,7 +35,7 @@ module Dolt
|
|
35
35
|
end
|
36
36
|
|
37
37
|
get "/:repo" do
|
38
|
-
redirect "/#{params[:repo]}/tree/
|
38
|
+
redirect "/#{params[:repo]}/tree/HEAD:"
|
39
39
|
end
|
40
40
|
|
41
41
|
get "/*/tree/*:*" do
|
@@ -48,7 +48,7 @@ module Dolt
|
|
48
48
|
end
|
49
49
|
|
50
50
|
get "/*/tree/*" do
|
51
|
-
force_ref(params[:splat], "tree", "
|
51
|
+
force_ref(params[:splat], "tree", "HEAD")
|
52
52
|
end
|
53
53
|
|
54
54
|
get "/*/blob/*:*" do
|
@@ -61,7 +61,7 @@ module Dolt
|
|
61
61
|
end
|
62
62
|
|
63
63
|
get "/*/blob/*" do
|
64
|
-
force_ref(params[:splat], "blob", "
|
64
|
+
force_ref(params[:splat], "blob", "HEAD")
|
65
65
|
end
|
66
66
|
|
67
67
|
get "/*/raw/*:*" do
|
@@ -74,7 +74,7 @@ module Dolt
|
|
74
74
|
end
|
75
75
|
|
76
76
|
get "/*/raw/*" do
|
77
|
-
force_ref(params[:splat], "raw", "
|
77
|
+
force_ref(params[:splat], "raw", "HEAD")
|
78
78
|
end
|
79
79
|
|
80
80
|
get "/*/blame/*:*" do
|
@@ -87,7 +87,7 @@ module Dolt
|
|
87
87
|
end
|
88
88
|
|
89
89
|
get "/*/blame/*" do
|
90
|
-
force_ref(params[:splat], "blame", "
|
90
|
+
force_ref(params[:splat], "blame", "HEAD")
|
91
91
|
end
|
92
92
|
|
93
93
|
get "/*/history/*:*" do
|
@@ -100,7 +100,7 @@ module Dolt
|
|
100
100
|
end
|
101
101
|
|
102
102
|
get "/*/history/*" do
|
103
|
-
force_ref(params[:splat], "history", "
|
103
|
+
force_ref(params[:splat], "history", "HEAD")
|
104
104
|
end
|
105
105
|
|
106
106
|
get "/*/refs" do
|
@@ -36,7 +36,7 @@ module Dolt
|
|
36
36
|
not_found { renderer.render("404") }
|
37
37
|
|
38
38
|
get "/" do
|
39
|
-
redirect("/tree/
|
39
|
+
redirect("/tree/HEAD:")
|
40
40
|
end
|
41
41
|
|
42
42
|
get "/tree/*:*" do
|
@@ -49,7 +49,7 @@ module Dolt
|
|
49
49
|
end
|
50
50
|
|
51
51
|
get "/tree/*" do
|
52
|
-
force_ref(params[:splat], "tree", "
|
52
|
+
force_ref(params[:splat], "tree", "HEAD")
|
53
53
|
end
|
54
54
|
|
55
55
|
get "/blob/*:*" do
|
@@ -62,7 +62,7 @@ module Dolt
|
|
62
62
|
end
|
63
63
|
|
64
64
|
get "/blob/*" do
|
65
|
-
force_ref(params[:splat], "blob", "
|
65
|
+
force_ref(params[:splat], "blob", "HEAD")
|
66
66
|
end
|
67
67
|
|
68
68
|
get "/raw/*:*" do
|
@@ -75,7 +75,7 @@ module Dolt
|
|
75
75
|
end
|
76
76
|
|
77
77
|
get "/raw/*" do
|
78
|
-
force_ref(params[:splat], "raw", "
|
78
|
+
force_ref(params[:splat], "raw", "HEAD")
|
79
79
|
end
|
80
80
|
|
81
81
|
get "/blame/*:*" do
|
@@ -88,7 +88,7 @@ module Dolt
|
|
88
88
|
end
|
89
89
|
|
90
90
|
get "/blame/*" do
|
91
|
-
force_ref(params[:splat], "blame", "
|
91
|
+
force_ref(params[:splat], "blame", "HEAD")
|
92
92
|
end
|
93
93
|
|
94
94
|
get "/history/*:*" do
|
@@ -101,7 +101,7 @@ module Dolt
|
|
101
101
|
end
|
102
102
|
|
103
103
|
get "/history/*" do
|
104
|
-
force_ref(params[:splat], "blame", "
|
104
|
+
force_ref(params[:splat], "blame", "HEAD")
|
105
105
|
end
|
106
106
|
|
107
107
|
get "/refs" do
|
@@ -42,6 +42,6 @@ describe Dolt::Sinatra::MultiRepoBrowser do
|
|
42
42
|
it "redirects repo requests to main tree" do
|
43
43
|
get "/gitorious.git"
|
44
44
|
assert_equal 302, last_response.status
|
45
|
-
assert_equal "/gitorious.git/tree/
|
45
|
+
assert_equal "/gitorious.git/tree/HEAD:", last_response.headers["Location"]
|
46
46
|
end
|
47
47
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dolt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.23.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -18,7 +18,7 @@ dependencies:
|
|
18
18
|
requirements:
|
19
19
|
- - ~>
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: '0.
|
21
|
+
version: '0.23'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -26,7 +26,7 @@ dependencies:
|
|
26
26
|
requirements:
|
27
27
|
- - ~>
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: '0.
|
29
|
+
version: '0.23'
|
30
30
|
- !ruby/object:Gem::Dependency
|
31
31
|
name: thin
|
32
32
|
requirement: !ruby/object:Gem::Requirement
|