wire-framework 0.1.2.8 → 0.1.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/app/repo/svn.rb +16 -16
- data/lib/wire.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3837b62bbbbddcde05b8ca122736933a7d7a27c5
|
4
|
+
data.tar.gz: 68f9eec294a11524fe8fb2ed393c5deabff9a038
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b30a1faf6b54fa35bd91f77872cf208547e49ff354bf3645f1400a076ab97bae202995d41315342def86e96a5fc09be9c2a58391fff651c0a83993ddd7b293eb
|
7
|
+
data.tar.gz: b55b97b38a79cc1344716d3225cc6fb04531773282764a652162c767077fef3a50a754f3b2a49e25b1dc54be7e3ba0b0f1ec319de52059eac0b9afd41f2f65ce
|
data/lib/app/repo/svn.rb
CHANGED
@@ -39,14 +39,14 @@ module Repo
|
|
39
39
|
# @param [String] id the relative path to the file
|
40
40
|
# @return [String] the file
|
41
41
|
def self.do_read_file(rev, web, path, repo, id)
|
42
|
-
|
42
|
+
options = "--username=#{$environment[:repos_user]} --password=#{$environment[:repos_password]}"
|
43
43
|
if rev.nil?
|
44
44
|
rev = 'HEAD'
|
45
45
|
end
|
46
46
|
if web.nil?
|
47
|
-
body = `svn cat #{
|
47
|
+
body = `svn cat #{options} -r #{rev} 'svn://localhost/#{repo}/#{id}'`
|
48
48
|
else
|
49
|
-
body = `svn cat #{
|
49
|
+
body = `svn cat #{options} -r #{rev} 'svn://localhost/#{repo}/#{web}/#{id}'`
|
50
50
|
end
|
51
51
|
|
52
52
|
if $?.success?
|
@@ -63,18 +63,18 @@ module Repo
|
|
63
63
|
# @param [String] id the relative path to the file
|
64
64
|
# @return [Array] the directory listing
|
65
65
|
def self.do_read_listing(web, path, repo, id = nil)
|
66
|
-
|
66
|
+
options = "--username=#{$environment[:repos_user]} --password=#{$environment[:repos_password]}"
|
67
67
|
if web.nil?
|
68
68
|
if id.nil?
|
69
|
-
list = `svn list #{
|
69
|
+
list = `svn list #{options} --xml 'svn://localhost/#{repo}'`
|
70
70
|
else
|
71
|
-
list = `svn list #{
|
71
|
+
list = `svn list #{options} --xml 'svn://localhost/#{repo}/#{id}'`
|
72
72
|
end
|
73
73
|
else
|
74
74
|
if id.nil?
|
75
|
-
list = `svn list #{
|
75
|
+
list = `svn list #{options} --xml 'svn://localhost/#{repo}/#{web}'`
|
76
76
|
else
|
77
|
-
list = `svn list #{
|
77
|
+
list = `svn list #{options} --xml 'svn://localhost/#{repo}/#{web}/#{id}'`
|
78
78
|
end
|
79
79
|
end
|
80
80
|
unless $?.exitstatus == 0
|
@@ -92,14 +92,14 @@ module Repo
|
|
92
92
|
# @param [String] id the relative path to the file
|
93
93
|
# @return [Hash] the metadata
|
94
94
|
def self.do_read_info(rev, web, path, repo, id)
|
95
|
-
|
95
|
+
options = "--username=#{$environment[:repos_user]} --password=#{$environment[:repos_password]}"
|
96
96
|
if rev.nil?
|
97
97
|
rev = 'HEAD'
|
98
98
|
end
|
99
99
|
if web.nil?
|
100
|
-
info = `svn info #{
|
100
|
+
info = `svn info #{options} -r #{rev} --xml 'svn://localhost/#{repo}/#{id}'`
|
101
101
|
else
|
102
|
-
info = `svn info #{
|
102
|
+
info = `svn info #{options} -r #{rev} --xml 'svn://localhost/#{repo}/#{web}/#{id}'`
|
103
103
|
end
|
104
104
|
|
105
105
|
unless $?.exitstatus == 0
|
@@ -117,14 +117,14 @@ module Repo
|
|
117
117
|
# @param [String] id the relative path to the file
|
118
118
|
# @return [String] the MIME type
|
119
119
|
def self.do_read_mime(rev, web, path, repo, id)
|
120
|
-
|
120
|
+
options = "--username=#{$environment[:repos_user]} --password=#{$environment[:repos_password]}"
|
121
121
|
if rev.nil?
|
122
122
|
rev = 'HEAD'
|
123
123
|
end
|
124
124
|
if web.nil?
|
125
|
-
mime = `svn propget #{
|
125
|
+
mime = `svn propget #{options} -r #{rev} --xml svn:mime-type 'svn://localhost/#{repo}/#{id}'`
|
126
126
|
else
|
127
|
-
mime = `svn propget #{
|
127
|
+
mime = `svn propget #{options} -r #{rev} --xml svn:mime-type 'svn://localhost/#{repo}/#{web}/#{id}'`
|
128
128
|
end
|
129
129
|
|
130
130
|
unless $?.success?
|
@@ -149,9 +149,9 @@ module Repo
|
|
149
149
|
# @param [String] user the Author of this change
|
150
150
|
# @return [Integer] status code
|
151
151
|
def self.do_update_file(web, path, repo, id, content, message, mime, user)
|
152
|
-
|
152
|
+
options = "--username=#{$environment[:repos_user]} --password=#{$environment[:repos_password]}"
|
153
153
|
status = 500
|
154
|
-
`svn checkout #{
|
154
|
+
`svn checkout #{options} svn://localhost/#{repo} /tmp/svn/#{repo}`
|
155
155
|
if $?.exitstatus == 0
|
156
156
|
|
157
157
|
if web.nil?
|
data/lib/wire.rb
CHANGED