meta_project 0.4.13 → 0.4.14
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGES +6 -0
- data/README +1 -1
- data/Rakefile +1 -1
- data/lib/meta_project/project/xforge/session.rb +1 -1
- data/lib/meta_project/project/xforge/xforge_base.rb +13 -9
- data/lib/meta_project.rb +8 -0
- metadata +71 -69
data/CHANGES
CHANGED
data/README
CHANGED
data/Rakefile
CHANGED
@@ -24,7 +24,7 @@ require 'rake/rdoctask'
|
|
24
24
|
#
|
25
25
|
# REMEMBER TO KEEP PKG_VERSION IN SYNC WITH THE CHANGES FILE!
|
26
26
|
PKG_NAME = "meta_project"
|
27
|
-
PKG_VERSION = "0.4.
|
27
|
+
PKG_VERSION = "0.4.14"
|
28
28
|
PKG_FILE_NAME = "#{PKG_NAME}-#{PKG_VERSION}"
|
29
29
|
PKG_FILES = FileList[
|
30
30
|
'[A-Z]*',
|
@@ -34,7 +34,7 @@ module MetaProject
|
|
34
34
|
def initialize(host, project, cookie) # :nodoc:
|
35
35
|
@host = host
|
36
36
|
@project = project
|
37
|
-
@request_headers = { "Cookie" => cookie }
|
37
|
+
@request_headers = { "Cookie" => cookie }.merge(DEFAULT_POST_OPTIONS)
|
38
38
|
end
|
39
39
|
|
40
40
|
# This will get the +package_id+ for the project. This accepts an
|
@@ -26,19 +26,23 @@ module MetaProject
|
|
26
26
|
|
27
27
|
# Logs in and returns a Session
|
28
28
|
def login(user_name, password)
|
29
|
-
|
29
|
+
url = "/account/login.php"
|
30
|
+
data = [
|
31
|
+
"return_to=",
|
32
|
+
"login=Login",
|
33
|
+
"form_loginname=#{user_name}",
|
34
|
+
"form_pw=#{password}"
|
35
|
+
].join("&")
|
30
36
|
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
"form_loginname=#{user_name}",
|
35
|
-
"form_pw=#{password}"
|
36
|
-
].join("&")
|
37
|
-
http.post("/account/login.php", data)
|
37
|
+
http = Net::HTTP.new(@host, 80)
|
38
|
+
login_response, body = http.start do |http|
|
39
|
+
http.post(url, data, DEFAULT_POST_OPTIONS)
|
38
40
|
end
|
39
41
|
|
40
42
|
cookie = login_response["set-cookie"]
|
41
|
-
|
43
|
+
unless cookie
|
44
|
+
raise "Login failed.\nURL:#{url}\nParams:#{data}\nResponse:#{login_response.to_hash.inspect}"
|
45
|
+
end
|
42
46
|
Session.new(@host, self, cookie)
|
43
47
|
end
|
44
48
|
|
data/lib/meta_project.rb
CHANGED
@@ -9,3 +9,11 @@ require 'meta_project/tracker'
|
|
9
9
|
require 'meta_project/scm_web'
|
10
10
|
require 'meta_project/version_parser'
|
11
11
|
require 'rake/contrib/xforge'
|
12
|
+
|
13
|
+
module MetaProject
|
14
|
+
DEFAULT_POST_OPTIONS = {
|
15
|
+
"Content-Type" => "application/x-www-form-urlencoded",
|
16
|
+
"User-Agent" => "curl/7.13.1 (powerpc-apple-darwin8.0) libcurl/7.13.1 OpenSSL/0.9.7i zlib/1.2.3",
|
17
|
+
"Pragma" => "no-cache"
|
18
|
+
}
|
19
|
+
end
|
metadata
CHANGED
@@ -3,94 +3,96 @@ rubygems_version: 0.8.11
|
|
3
3
|
specification_version: 1
|
4
4
|
name: meta_project
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.4.
|
7
|
-
date:
|
8
|
-
summary:
|
9
|
-
trackers."
|
6
|
+
version: 0.4.14
|
7
|
+
date: 2006-02-27 00:00:00 -06:00
|
8
|
+
summary: Ruby library for interacting with project hosting servers, scms and issue trackers.
|
10
9
|
require_paths:
|
11
|
-
|
10
|
+
- lib
|
12
11
|
email: aslak.hellesoy@gmail.com
|
13
12
|
homepage: http://xforge.rubyforge.org
|
14
13
|
rubyforge_project: xforge
|
15
|
-
description:
|
16
|
-
project hosting servers, issue trackers, scms and scm browsers."
|
14
|
+
description: MetaProject (formerly XForge) is a library that allows interaction with various project hosting servers, issue trackers, scms and scm browsers.
|
17
15
|
autorequire: meta_project
|
18
16
|
default_executable:
|
19
17
|
bindir: bin
|
20
18
|
has_rdoc: true
|
21
19
|
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
22
20
|
requirements:
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
version: 0.0.0
|
21
|
+
- - ">"
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 0.0.0
|
27
24
|
version:
|
28
25
|
platform: ruby
|
29
26
|
signing_key:
|
30
27
|
cert_chain:
|
31
28
|
authors:
|
32
|
-
|
29
|
+
- Aslak Hellesoy
|
33
30
|
files:
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
31
|
+
- CHANGES
|
32
|
+
- MIT-LICENSE
|
33
|
+
- Rakefile
|
34
|
+
- README
|
35
|
+
- lib/meta_project.rb
|
36
|
+
- lib/meta_project/patois.rb
|
37
|
+
- lib/meta_project/project.rb
|
38
|
+
- lib/meta_project/project_analyzer.rb
|
39
|
+
- lib/meta_project/scm_web.rb
|
40
|
+
- lib/meta_project/tracker.rb
|
41
|
+
- lib/meta_project/version_parser.rb
|
42
|
+
- lib/meta_project/core_ext/open_uri.rb
|
43
|
+
- lib/meta_project/core_ext/pathname.rb
|
44
|
+
- lib/meta_project/core_ext/string.rb
|
45
|
+
- lib/meta_project/http/multipart.rb
|
46
|
+
- lib/meta_project/patois/parser.rb
|
47
|
+
- lib/meta_project/project/base.rb
|
48
|
+
- lib/meta_project/project/codehaus.rb
|
49
|
+
- lib/meta_project/project/trac.rb
|
50
|
+
- lib/meta_project/project/xforge.rb
|
51
|
+
- lib/meta_project/project/codehaus/codehaus_project_svn.rb
|
52
|
+
- lib/meta_project/project/trac/trac_project.rb
|
53
|
+
- lib/meta_project/project/xforge/ruby_forge.rb
|
54
|
+
- lib/meta_project/project/xforge/session.rb
|
55
|
+
- lib/meta_project/project/xforge/source_forge.rb
|
56
|
+
- lib/meta_project/project/xforge/xfile.rb
|
57
|
+
- lib/meta_project/project/xforge/xforge_base.rb
|
58
|
+
- lib/meta_project/release/freshmeat.rb
|
59
|
+
- lib/meta_project/release/raa.rb
|
60
|
+
- lib/meta_project/scm_web/browser.rb
|
61
|
+
- lib/meta_project/scm_web/pathname.rb
|
62
|
+
- lib/meta_project/tracker/base.rb
|
63
|
+
- lib/meta_project/tracker/digit_issues.rb
|
64
|
+
- lib/meta_project/tracker/issue.rb
|
65
|
+
- lib/meta_project/tracker/jira.rb
|
66
|
+
- lib/meta_project/tracker/trac.rb
|
67
|
+
- lib/meta_project/tracker/xforge.rb
|
68
|
+
- lib/meta_project/tracker/jira/jira_issues.rb
|
69
|
+
- lib/meta_project/tracker/jira/jira_tracker.rb
|
70
|
+
- lib/meta_project/tracker/trac/trac_tracker.rb
|
71
|
+
- lib/meta_project/tracker/xforge/ruby_forge_tracker.rb
|
72
|
+
- lib/meta_project/tracker/xforge/source_forge_tracker.rb
|
73
|
+
- lib/meta_project/tracker/xforge/xforge_tracker.rb
|
74
|
+
- lib/rake/contrib/xforge.rb
|
75
|
+
- lib/rake/contrib/xforge/base.rb
|
76
|
+
- lib/rake/contrib/xforge/news_publisher.rb
|
77
|
+
- lib/rake/contrib/xforge/release.rb
|
78
|
+
- doc/base_attrs.rdoc
|
82
79
|
test_files: []
|
80
|
+
|
83
81
|
rdoc_options:
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
82
|
+
- --title
|
83
|
+
- MetaProject
|
84
|
+
- --main
|
85
|
+
- README
|
86
|
+
- --line-numbers
|
89
87
|
extra_rdoc_files:
|
90
|
-
|
91
|
-
|
92
|
-
|
88
|
+
- README
|
89
|
+
- MIT-LICENSE
|
90
|
+
- CHANGES
|
93
91
|
executables: []
|
92
|
+
|
94
93
|
extensions: []
|
94
|
+
|
95
95
|
requirements: []
|
96
|
-
|
96
|
+
|
97
|
+
dependencies: []
|
98
|
+
|