twitter2vk_reposter 0.2.2 → 0.2.4

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.
Files changed (3) hide show
  1. data/ChangeLog +6 -0
  2. data/bin/twitter2vk_reposter +5 -3
  3. metadata +8 -6
data/ChangeLog CHANGED
@@ -1,3 +1,9 @@
1
+ == 0.2.4 (Орешек)
2
+ * Fix repost several status.
3
+
4
+ == 0.2.3 (Шоколад)
5
+ * Fix installer to use new VK API.
6
+
1
7
  == 0.2.2 (Багет)
2
8
  * Installer can update previous config.
3
9
 
@@ -84,12 +84,14 @@ statuses = JSON.parse(request.read.to_s)
84
84
  unless statuses.empty?
85
85
  activityhash = load_vk_activityhash(config['vk_session'])
86
86
 
87
- statuses.each do |status|
87
+ last_message_id = nil
88
+ statuses.reverse.each do |status|
88
89
  text = format_status(status, config)
90
+ last_message_id = status['id']
89
91
  next unless repost? text, config
90
92
  set_status_to_vk(text, config['vk_session'], activityhash)
91
- sleep 10 unless statuses.last == status
93
+ break
92
94
  end
93
95
 
94
- File.open(config['last_message'], 'w') { |io| io << statuses.first['id'] }
96
+ File.open(config['last_message'], 'w') { |io| io << last_message_id }
95
97
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twitter2vk_reposter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrey "A.I." Sitnik
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-10-18 00:00:00 +04:00
12
+ date: 2009-11-05 00:00:00 +03:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -32,7 +32,7 @@ dependencies:
32
32
  - !ruby/object:Gem::Version
33
33
  version: "0"
34
34
  version:
35
- description: "Server script to repost Twitter statuses to VK (\xD0\x92 \xD0\x9A\xD0\xBE\xD0\xBD\xD1\x82\xD0\xB0\xD0\xBA\xD1\x82\xD0\xB5). Install twitter2vk to create config and cron task for it."
35
+ description: " Server script to repost Twitter statuses to VK (\xD0\x92 \xD0\x9A\xD0\xBE\xD0\xBD\xD1\x82\xD0\xB0\xD0\xBA\xD1\x82\xD0\xB5).\n Install twitter2vk to create config and cron task for it.\n"
36
36
  email: andrey@sitnik.ru
37
37
  executables:
38
38
  - twitter2vk_reposter
@@ -45,8 +45,10 @@ files:
45
45
  - README.markdown
46
46
  - ChangeLog
47
47
  - COPYING
48
- has_rdoc: false
48
+ has_rdoc: true
49
49
  homepage:
50
+ licenses: []
51
+
50
52
  post_install_message:
51
53
  rdoc_options: []
52
54
 
@@ -67,9 +69,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
67
69
  requirements: []
68
70
 
69
71
  rubyforge_project: twitter2vk
70
- rubygems_version: 1.3.1
72
+ rubygems_version: 1.3.5
71
73
  signing_key:
72
- specification_version: 2
74
+ specification_version: 3
73
75
  summary: "Atomatic repost Twitter statuses to VK (\xD0\x92 \xD0\x9A\xD0\xBE\xD0\xBD\xD1\x82\xD0\xB0\xD0\xBA\xD1\x82\xD0\xB5)."
74
76
  test_files: []
75
77