class JsonVoorhees::AppMakeUserGenerator

Public Instance Methods

sprint() click to toggle source
# File lib/generators/json_voorhees/app_make_user/app_make_user_generator.rb, line 6
def sprint
  route "mount Arcadex::Engine, at: \'/\'"
  if options.fbonly?
    fb_only
  else
    people
  end
end

Private Instance Methods

fb_only() click to toggle source
# File lib/generators/json_voorhees/app_make_user/app_make_user_generator.rb, line 17
def fb_only
  run "git clone https://github.com/cleor41/fbuser.git"
  run "mv fbuser engines/fbuser"
  run "rm -rf engines/fbuser/.git"
  #Need to add the engine to the main_apps gemfile
  route "mount Fbuser::Engine, at: \'/\'"
  insert_fb_user_engine
  run "rails g fbuser:all"
end
insert_fb_user_engine() click to toggle source
# File lib/generators/json_voorhees/app_make_user/app_make_user_generator.rb, line 27
      def insert_fb_user_engine
        inject_into_file 'Gemfile', after: "source \'https://rubygems.org\'\n" do <<-'RUBY'

  gem 'fbuser', :path => "engines/fbuser"

        RUBY
        end
      end
insert_people_engine() click to toggle source
# File lib/generators/json_voorhees/app_make_user/app_make_user_generator.rb, line 46
      def insert_people_engine
                        inject_into_file 'Gemfile', after: "source \'https://rubygems.org\'\n" do <<-'RUBY'

  gem 'people', :path => "engines/people"

                        RUBY
                        end
      end
people() click to toggle source
# File lib/generators/json_voorhees/app_make_user/app_make_user_generator.rb, line 36
def people
  run "git clone https://github.com/cleor41/people.git"
  run "mv people engines/people"
  run "rm -rf engines/people/.git"
          #Need to add the engine to the main_apps gemfile
  route "mount People::Engine, at: \'/\'"
  insert_people_engine
  run "rails g people:all"
end