wifi_location 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +4 -1
- data/README.rdoc +1 -0
- data/bin/whereami +5 -12
- data/lib/wifi_location.rb +1 -1
- metadata +88 -97
data/History.txt
CHANGED
data/README.rdoc
CHANGED
data/bin/whereami
CHANGED
@@ -24,31 +24,24 @@ if parser.has_option? :version
|
|
24
24
|
exit
|
25
25
|
end
|
26
26
|
|
27
|
+
towers = WiFiLocation.wifi_towers
|
28
|
+
|
27
29
|
if parser.has_option? :towers
|
28
|
-
puts
|
30
|
+
puts towers.to_json
|
29
31
|
exit
|
30
32
|
end
|
31
33
|
|
34
|
+
location = WiFiLocation.location towers
|
35
|
+
|
32
36
|
if parser.has_option? :dump
|
33
|
-
towers = WiFiLocation.wifi_towers
|
34
|
-
location = WiFiLocation.location towers
|
35
37
|
h = {:towers => towers, :location => location}
|
36
38
|
puts h.to_json
|
37
39
|
exit
|
38
40
|
end
|
39
41
|
|
40
42
|
if parser.has_option? :map
|
41
|
-
location = WiFiLocation.location
|
42
43
|
puts url = "https://maps.google.com/?ll=#{location['latitude']},#{location['longitude']}"
|
43
|
-
['xdg-open', 'open'].each do |cmd|
|
44
|
-
cmd = `which #{cmd}`.strip
|
45
|
-
unless cmd.empty?
|
46
|
-
system "#{cmd} #{url}"
|
47
|
-
break
|
48
|
-
end
|
49
|
-
end
|
50
44
|
exit
|
51
45
|
end
|
52
46
|
|
53
|
-
location = WiFiLocation.location
|
54
47
|
puts "lat=#{location['latitude']},lon=#{location['longitude']}"
|
data/lib/wifi_location.rb
CHANGED
metadata
CHANGED
@@ -1,112 +1,107 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: wifi_location
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.3
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 0
|
9
|
-
- 2
|
10
|
-
version: 0.0.2
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Sho Hashimoto
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
12
|
+
date: 2012-08-03 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: json
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
23
17
|
none: false
|
24
|
-
requirements:
|
25
|
-
- -
|
26
|
-
- !ruby/object:Gem::Version
|
27
|
-
hash: 5
|
28
|
-
segments:
|
29
|
-
- 1
|
30
|
-
- 5
|
31
|
-
- 3
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
32
21
|
version: 1.5.3
|
33
22
|
type: :runtime
|
34
|
-
name: json
|
35
|
-
version_requirements: *id001
|
36
|
-
- !ruby/object:Gem::Dependency
|
37
23
|
prerelease: false
|
38
|
-
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ! '>='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 1.5.3
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: args_parser
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
39
33
|
none: false
|
40
|
-
requirements:
|
41
|
-
- -
|
42
|
-
- !ruby/object:Gem::Version
|
43
|
-
hash: 27
|
44
|
-
segments:
|
45
|
-
- 0
|
46
|
-
- 0
|
47
|
-
- 2
|
34
|
+
requirements:
|
35
|
+
- - ! '>='
|
36
|
+
- !ruby/object:Gem::Version
|
48
37
|
version: 0.0.2
|
49
38
|
type: :runtime
|
50
|
-
name: args_parser
|
51
|
-
version_requirements: *id002
|
52
|
-
- !ruby/object:Gem::Dependency
|
53
39
|
prerelease: false
|
54
|
-
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: 0.0.2
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: rdoc
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
55
49
|
none: false
|
56
|
-
requirements:
|
50
|
+
requirements:
|
57
51
|
- - ~>
|
58
|
-
- !ruby/object:Gem::Version
|
59
|
-
|
60
|
-
segments:
|
61
|
-
- 3
|
62
|
-
- 10
|
63
|
-
version: "3.10"
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '3.10'
|
64
54
|
type: :development
|
65
|
-
name: rdoc
|
66
|
-
version_requirements: *id003
|
67
|
-
- !ruby/object:Gem::Dependency
|
68
55
|
prerelease: false
|
69
|
-
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
70
57
|
none: false
|
71
|
-
requirements:
|
72
|
-
- -
|
73
|
-
- !ruby/object:Gem::Version
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
58
|
+
requirements:
|
59
|
+
- - ~>
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '3.10'
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: newgem
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
66
|
+
requirements:
|
67
|
+
- - ! '>='
|
68
|
+
- !ruby/object:Gem::Version
|
79
69
|
version: 1.5.3
|
80
70
|
type: :development
|
81
|
-
name: newgem
|
82
|
-
version_requirements: *id004
|
83
|
-
- !ruby/object:Gem::Dependency
|
84
71
|
prerelease: false
|
85
|
-
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: 1.5.3
|
78
|
+
- !ruby/object:Gem::Dependency
|
79
|
+
name: hoe
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
86
81
|
none: false
|
87
|
-
requirements:
|
82
|
+
requirements:
|
88
83
|
- - ~>
|
89
|
-
- !ruby/object:Gem::Version
|
90
|
-
|
91
|
-
segments:
|
92
|
-
- 3
|
93
|
-
- 0
|
94
|
-
version: "3.0"
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: '3.0'
|
95
86
|
type: :development
|
96
|
-
|
97
|
-
version_requirements:
|
87
|
+
prerelease: false
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
90
|
+
requirements:
|
91
|
+
- - ~>
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '3.0'
|
98
94
|
description: Get your location with WiFi Mac Address and GoogleMap.
|
99
|
-
email:
|
95
|
+
email:
|
100
96
|
- hashimoto@shokai.org
|
101
|
-
executables:
|
97
|
+
executables:
|
102
98
|
- whereami
|
103
99
|
extensions: []
|
104
|
-
|
105
|
-
extra_rdoc_files:
|
100
|
+
extra_rdoc_files:
|
106
101
|
- History.txt
|
107
102
|
- Manifest.txt
|
108
103
|
- README.rdoc
|
109
|
-
files:
|
104
|
+
files:
|
110
105
|
- History.txt
|
111
106
|
- Manifest.txt
|
112
107
|
- README.rdoc
|
@@ -122,38 +117,34 @@ files:
|
|
122
117
|
- .gemtest
|
123
118
|
homepage: http://github.com/shokai/wifi_location
|
124
119
|
licenses: []
|
125
|
-
|
126
|
-
|
127
|
-
rdoc_options:
|
120
|
+
post_install_message: ! '!! You can get your location with "whereami" command. For
|
121
|
+
more information on wifi_location, see https://rubygems.org/gems/wifi_location'
|
122
|
+
rdoc_options:
|
128
123
|
- --main
|
129
124
|
- README.rdoc
|
130
|
-
require_paths:
|
125
|
+
require_paths:
|
131
126
|
- lib
|
132
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
127
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
133
128
|
none: false
|
134
|
-
requirements:
|
135
|
-
- -
|
136
|
-
- !ruby/object:Gem::Version
|
137
|
-
|
138
|
-
segments:
|
129
|
+
requirements:
|
130
|
+
- - ! '>='
|
131
|
+
- !ruby/object:Gem::Version
|
132
|
+
version: '0'
|
133
|
+
segments:
|
139
134
|
- 0
|
140
|
-
|
141
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
135
|
+
hash: 1142043331478438304
|
136
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
142
137
|
none: false
|
143
|
-
requirements:
|
144
|
-
- -
|
145
|
-
- !ruby/object:Gem::Version
|
146
|
-
|
147
|
-
segments:
|
148
|
-
- 0
|
149
|
-
version: "0"
|
138
|
+
requirements:
|
139
|
+
- - ! '>='
|
140
|
+
- !ruby/object:Gem::Version
|
141
|
+
version: '0'
|
150
142
|
requirements: []
|
151
|
-
|
152
143
|
rubyforge_project: wifi_location
|
153
144
|
rubygems_version: 1.8.24
|
154
145
|
signing_key:
|
155
146
|
specification_version: 3
|
156
147
|
summary: Get your location with WiFi Mac Address and GoogleMap.
|
157
|
-
test_files:
|
148
|
+
test_files:
|
158
149
|
- test/test_helper.rb
|
159
150
|
- test/test_wifi_location.rb
|