galapagos_mobile 0.0.4 → 0.0.5
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.
- data/Gemfile +0 -4
- data/README.md +14 -5
- data/galapagos_mobile.gemspec +0 -1
- data/init.rb +1 -0
- data/lib/galapagos_mobile/jpmobile.rb +15 -0
- data/lib/galapagos_mobile/rails.rb +1 -15
- data/lib/galapagos_mobile/version.rb +1 -1
- data/lib/galapagos_mobile.rb +10 -3
- metadata +4 -13
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -12,11 +12,6 @@ jpmobileプラグインを使用した場合に発生する不具合を解消す
|
|
12
12
|
|
13
13
|
## install
|
14
14
|
|
15
|
-
### Rails pluginとしてインストール
|
16
|
-
|
17
|
-
$ rails plugin install git://github.com/matsuda/galapagos_mobile.git
|
18
|
-
|
19
|
-
|
20
15
|
### gemとしてインストール
|
21
16
|
|
22
17
|
Gemfileに以下を記述
|
@@ -27,6 +22,20 @@ bundle
|
|
27
22
|
|
28
23
|
$ bundle
|
29
24
|
|
25
|
+
setupメソッドを実行
|
26
|
+
例えば config/initializers/galapagos_mobile.rb を作って
|
27
|
+
|
28
|
+
GalapagosMobile.setup
|
29
|
+
|
30
|
+
と記述する
|
31
|
+
|
32
|
+
### Rails pluginとしてインストール
|
33
|
+
|
34
|
+
(setupメソッドは不要)
|
35
|
+
|
36
|
+
$ rails plugin install git://github.com/matsuda/galapagos_mobile.git
|
37
|
+
|
38
|
+
|
30
39
|
## 実装されている機能
|
31
40
|
|
32
41
|
* Cookie非対応の携帯でログイン処理を可能にする。
|
data/galapagos_mobile.gemspec
CHANGED
data/init.rb
CHANGED
@@ -0,0 +1,15 @@
|
|
1
|
+
begin
|
2
|
+
require 'jpmobile'
|
3
|
+
rescue LoadError, NameError => e
|
4
|
+
$stderr.puts "You don't have jpmobile installed in your application. " +
|
5
|
+
"Please add it to your Gemfile and run bundle install or rails plugin install from github's repository"
|
6
|
+
raise e
|
7
|
+
end
|
8
|
+
|
9
|
+
ActiveSupport.on_load(:action_controller) do
|
10
|
+
require 'galapagos_mobile/trans_sid'
|
11
|
+
end
|
12
|
+
|
13
|
+
if defined?(Devise)
|
14
|
+
require 'galapagos_mobile/devise'
|
15
|
+
end
|
@@ -1,15 +1 @@
|
|
1
|
-
|
2
|
-
require 'jpmobile'
|
3
|
-
rescue LoadError, NameError => e
|
4
|
-
$stderr.puts "You don't have jpmobile installed in your application. " +
|
5
|
-
"Please add it to your Gemfile and run bundle install or rails plugin install from github's repository"
|
6
|
-
raise e
|
7
|
-
end
|
8
|
-
|
9
|
-
ActiveSupport.on_load(:action_controller) do
|
10
|
-
require 'galapagos_mobile/trans_sid'
|
11
|
-
end
|
12
|
-
|
13
|
-
if defined?(Devise)
|
14
|
-
require 'galapagos_mobile/devise'
|
15
|
-
end
|
1
|
+
require 'galapagos_mobile/jpmobile'
|
data/lib/galapagos_mobile.rb
CHANGED
@@ -2,8 +2,15 @@ $:.unshift(File.dirname(__FILE__)) unless $:.include?(File.dirname(__FILE__)) ||
|
|
2
2
|
$:.include?(File.expand_path(File.dirname(__FILE__)))
|
3
3
|
|
4
4
|
module GalapagosMobile
|
5
|
-
|
5
|
+
class << self
|
6
|
+
def add_features_to_rails
|
7
|
+
if defined?(Rails)
|
8
|
+
require 'galapagos_mobile/rails'
|
9
|
+
end
|
10
|
+
end
|
6
11
|
|
7
|
-
|
8
|
-
|
12
|
+
def setup
|
13
|
+
add_features_to_rails
|
14
|
+
end
|
15
|
+
end
|
9
16
|
end
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: galapagos_mobile
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.0.
|
5
|
+
version: 0.0.5
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Kosuke Matsuda
|
@@ -12,18 +12,8 @@ cert_chain: []
|
|
12
12
|
|
13
13
|
date: 2011-02-17 00:00:00 +09:00
|
14
14
|
default_executable:
|
15
|
-
dependencies:
|
16
|
-
|
17
|
-
name: jpmobile
|
18
|
-
prerelease: false
|
19
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
20
|
-
none: false
|
21
|
-
requirements:
|
22
|
-
- - ">="
|
23
|
-
- !ruby/object:Gem::Version
|
24
|
-
version: 0.1.4
|
25
|
-
type: :runtime
|
26
|
-
version_requirements: *id001
|
15
|
+
dependencies: []
|
16
|
+
|
27
17
|
description: A Ruby on Rails plugin to patch jpmobile
|
28
18
|
email:
|
29
19
|
- hi@matsuda.me
|
@@ -45,6 +35,7 @@ files:
|
|
45
35
|
- install.rb
|
46
36
|
- lib/galapagos_mobile.rb
|
47
37
|
- lib/galapagos_mobile/devise.rb
|
38
|
+
- lib/galapagos_mobile/jpmobile.rb
|
48
39
|
- lib/galapagos_mobile/rails.rb
|
49
40
|
- lib/galapagos_mobile/trans_sid.rb
|
50
41
|
- lib/galapagos_mobile/version.rb
|