thartm 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/VERSION +1 -1
  2. data/bin/rrtm +1 -1
  3. data/lib/thartm_lib.rb +11 -3
  4. metadata +35 -33
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.4
1
+ 0.1.5
data/bin/rrtm CHANGED
@@ -1,4 +1,4 @@
1
- #!/usr/bin/ruby
1
+ #!/usr/bin/env ruby
2
2
  require File.dirname(__FILE__) + '/../lib/thartm.rb'
3
3
 
4
4
  CONFIGFILE = File.join(File.expand_path(ENV['HOME']), '.rtm')
data/lib/thartm_lib.rb CHANGED
@@ -25,12 +25,16 @@
25
25
  #TODO add yaml api check?
26
26
 
27
27
  require 'uri'
28
- require 'md5'
28
+ if /^1\.9/ === RUBY_VERSION then
29
+ require 'digest/md5'
30
+ else
31
+ require 'md5'
32
+ require 'parsedate'
33
+ end
29
34
  require 'cgi'
30
35
  require 'net/http'
31
36
  require 'date'
32
37
  require 'time'
33
- require 'parsedate'
34
38
  require 'rubygems'
35
39
  require 'xml/libxml'
36
40
  require 'tzinfo'
@@ -405,7 +409,11 @@ class ThaRememberTheMilk
405
409
  end
406
410
 
407
411
  def sign_request( args )
408
- return MD5.md5(@shared_secret + args.sort.flatten.join).to_s
412
+ if /^1\.9/ === RUBY_VERSION then
413
+ return (Digest::MD5.new << @shared_secret + args.sort.flatten.join).to_s
414
+ else
415
+ return MD5.md5(@shared_secret + args.sort.flatten.join).to_s
416
+ end
409
417
  end
410
418
  end
411
419
 
metadata CHANGED
@@ -1,7 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thartm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ hash: 17
5
+ prerelease: false
6
+ segments:
7
+ - 0
8
+ - 1
9
+ - 5
10
+ version: 0.1.5
5
11
  platform: ruby
6
12
  authors:
7
13
  - tha
@@ -9,49 +15,37 @@ autorequire:
9
15
  bindir: bin
10
16
  cert_chain: []
11
17
 
12
- date: 2010-07-06 00:00:00 +02:00
18
+ date: 2010-09-27 00:00:00 +02:00
13
19
  default_executable: rrtm
14
20
  dependencies:
15
21
  - !ruby/object:Gem::Dependency
16
22
  name: tzinfo
17
- type: :runtime
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
20
26
  requirements:
21
27
  - - ">="
22
28
  - !ruby/object:Gem::Version
29
+ hash: 3
30
+ segments:
31
+ - 0
23
32
  version: "0"
24
- version:
25
- - !ruby/object:Gem::Dependency
26
- name: libxml-ruby
27
33
  type: :runtime
28
- version_requirement:
29
- version_requirements: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - ">="
32
- - !ruby/object:Gem::Version
33
- version: "0"
34
- version:
35
- - !ruby/object:Gem::Dependency
36
- name: tzinfo
37
- type: :runtime
38
- version_requirement:
39
- version_requirements: !ruby/object:Gem::Requirement
40
- requirements:
41
- - - ">="
42
- - !ruby/object:Gem::Version
43
- version: "0"
44
- version:
34
+ version_requirements: *id001
45
35
  - !ruby/object:Gem::Dependency
46
36
  name: libxml-ruby
47
- type: :runtime
48
- version_requirement:
49
- version_requirements: !ruby/object:Gem::Requirement
37
+ prerelease: false
38
+ requirement: &id002 !ruby/object:Gem::Requirement
39
+ none: false
50
40
  requirements:
51
41
  - - ">="
52
42
  - !ruby/object:Gem::Version
43
+ hash: 3
44
+ segments:
45
+ - 0
53
46
  version: "0"
54
- version:
47
+ type: :runtime
48
+ version_requirements: *id002
55
49
  description: rtmapi fixed version with a simple cli added, rtmapi package fixed to work with libxml2 version > 2.7
56
50
  email: thamayor@gmail.com
57
51
  executables:
@@ -73,29 +67,37 @@ files:
73
67
  - test/test_thartm.rb
74
68
  has_rdoc: true
75
69
  homepage: http://github.com/ghedamat/thartm
70
+ licenses: []
71
+
76
72
  post_install_message:
77
73
  rdoc_options:
78
74
  - --charset=UTF-8
79
75
  require_paths:
80
76
  - lib
81
77
  required_ruby_version: !ruby/object:Gem::Requirement
78
+ none: false
82
79
  requirements:
83
80
  - - ">="
84
81
  - !ruby/object:Gem::Version
82
+ hash: 3
83
+ segments:
84
+ - 0
85
85
  version: "0"
86
- version:
87
86
  required_rubygems_version: !ruby/object:Gem::Requirement
87
+ none: false
88
88
  requirements:
89
89
  - - ">="
90
90
  - !ruby/object:Gem::Version
91
+ hash: 3
92
+ segments:
93
+ - 0
91
94
  version: "0"
92
- version:
93
95
  requirements: []
94
96
 
95
97
  rubyforge_project:
96
- rubygems_version: 1.3.1
98
+ rubygems_version: 1.3.7
97
99
  signing_key:
98
- specification_version: 2
100
+ specification_version: 3
99
101
  summary: rtmapi based remember the milk cli.
100
102
  test_files:
101
103
  - test/helper.rb