Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

2.x #11

Open
wants to merge 3 commits into from

2 participants

@gnarg

I needed to use mobile-fu as a gem in my rails 2.3.8 project. These are the changes I made for that to work.

Jon Guymon added some commits
@SentulAsia SentulAsia referenced this pull request from a commit in brainstormtech/mobile-fu
@SentulAsia SentulAsia fixed #9 #11 removed mobile user agent and fixed readme 6e91e94
@benlangfeld

This project is abandoned. Please see the active fork at http://github.com/benlangfeld/mobile-fu. Please test with the released gem and master branch of the new home for the project, and file an issue on the other repo if you still have problems.

See #40.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Oct 7, 2010
  1. gem config

    Jon Guymon authored
  2. gem config

    Jon Guymon authored
Commits on Oct 8, 2010
  1. working on correct gemspec

    Jon Guymon authored
This page is out of date. Refresh to see the latest.
View
15 Rakefile
@@ -2,6 +2,20 @@ require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
+begin
+ require 'jeweler'
+ Jeweler::Tasks.new do |gemspec|
+ gemspec.name = "mobile_fu"
+ gemspec.summary = "Automatically detect mobile devices that access your Rails application"
+ gemspec.description = "Want to automatically detect mobile devices that access your Rails application? Mobile Fu allows you to do just that. People can access your site from a Palm, Blackberry, iPhone, iPad, Nokia, etc. and it will automatically adjust the format of the request from :html to :mobile."
+ gemspec.email = "brendangl@gmail.com"
+ gemspec.homepage = "http://github.com/brendanlim/mobile-fu"
+ gemspec.authors = ["Brendan G. Lim"]
+ end
+rescue LoadError
+ puts "Jeweler not available. Install it with: gem install jeweler"
+end
+
desc 'Default: run unit tests.'
task :default => :test
@@ -20,3 +34,4 @@ Rake::RDocTask.new(:rdoc) do |rdoc|
rdoc.rdoc_files.include('README')
rdoc.rdoc_files.include('lib/**/*.rb')
end
+
View
1  VERSION
@@ -0,0 +1 @@
+0.3.0
View
8 init.rb
@@ -1,7 +1 @@
-require File.dirname(__FILE__) + '/lib/mobile_fu_helper.rb'
-require File.dirname(__FILE__) + '/lib/mobilized_styles'
-require File.dirname(__FILE__) + '/lib/mobile_fu'
-
-ActionView::Base.send(:include, MobileFuHelper)
-ActionView::Base.send(:include, MobilizedStyles)
-ActionView::Base.send(:alias_method_chain, :stylesheet_link_tag, :mobilization)
+require File.dirname(__FILE__)+'/rails/init.rb'
View
56 mobile_fu.gemspec
@@ -0,0 +1,56 @@
+# Generated by jeweler
+# DO NOT EDIT THIS FILE DIRECTLY
+# Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
+# -*- encoding: utf-8 -*-
+
+Gem::Specification.new do |s|
+ s.name = %q{mobile_fu}
+ s.version = "0.3.0"
+
+ s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
+ s.authors = ["Brendan G. Lim"]
+ s.date = %q{2010-10-08}
+ s.description = %q{Want to automatically detect mobile devices that access your Rails application? Mobile Fu allows you to do just that. People can access your site from a Palm, Blackberry, iPhone, iPad, Nokia, etc. and it will automatically adjust the format of the request from :html to :mobile.}
+ s.email = %q{brendangl@gmail.com}
+ s.extra_rdoc_files = [
+ "README.rdoc"
+ ]
+ s.files = [
+ "CHANGELOG",
+ "MIT-LICENSE",
+ "README.rdoc",
+ "Rakefile",
+ "VERSION",
+ "init.rb",
+ "install.rb",
+ "lib/mobile_fu.rb",
+ "lib/mobile_fu_helper.rb",
+ "lib/mobilized_styles.rb",
+ "mobile_fu.gemspec",
+ "rails/init.rb",
+ "spec/mobilized_styles_spec.rb",
+ "spec/spec.opts",
+ "spec/spec_helper.rb",
+ "uninstall.rb"
+ ]
+ s.homepage = %q{http://github.com/brendanlim/mobile-fu}
+ s.rdoc_options = ["--charset=UTF-8"]
+ s.require_paths = ["lib"]
+ s.rubygems_version = %q{1.3.7}
+ s.summary = %q{Automatically detect mobile devices that access your Rails application}
+ s.test_files = [
+ "spec/mobilized_styles_spec.rb",
+ "spec/spec_helper.rb"
+ ]
+
+ if s.respond_to? :specification_version then
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
+ s.specification_version = 3
+
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
+ else
+ end
+ else
+ end
+end
+
View
7 rails/init.rb
@@ -0,0 +1,7 @@
+require File.dirname(__FILE__) + '/../lib/mobile_fu_helper.rb'
+require File.dirname(__FILE__) + '/../lib/mobilized_styles'
+require File.dirname(__FILE__) + '/../lib/mobile_fu'
+
+ActionView::Base.send(:include, MobileFuHelper)
+ActionView::Base.send(:include, MobilizedStyles)
+ActionView::Base.send(:alias_method_chain, :stylesheet_link_tag, :mobilization)
Something went wrong with that request. Please try again.