I am new to rails and just created simple "empty" app in heroku and synchronized that with my dropbox account. I was able to open heroku site in web browser, then I changed index.rb and deployed the application and changes was done correctly , I saw the result in web browser.
So the application in dropbox folder works correctly BUT I am not able to run it locally. When I type rails server in project folder it just not recognized the project and gave me:
C:\Users\Dav\Dropbox\Apps\Heroku\aqueous-waters-4632>rails server
DL is deprecated, please use Fiddle
Usage:
rails new APP_PATH [options]
Options:
-r, [--ruby=PATH] # Path to the Ruby bina
ry of your choice
# Default: C:/RailsInst
aller/Ruby2.0.0/bin/ruby.exe
-m, [--template=TEMPLATE] # Path to some applicat
ion template (can be a filesystem path or URL)
[--skip-gemfile], [--no-skip-gemfile] # Don't create a Gemfil
e
-B, [--skip-bundle], [--no-skip-bundle] # Don't run bundle inst
all
-G, [--skip-git], [--no-skip-git] # Skip .gitignore file
[--skip-keeps], [--no-skip-keeps] # Skip source control .
keep files
-O, [--skip-active-record], [--no-skip-active-record] # Skip Active Record fi
les
-V, [--skip-action-view], [--no-skip-action-view] # Skip Action View file
s
-S, [--skip-sprockets], [--no-skip-sprockets] # Skip Sprockets files
[--skip-spring], [--no-skip-spring] # Don't install Spring
application preloader
-d, [--database=DATABASE] # Preconfigure for sele
cted database (options: mysql/oracle/postgresql/sqlite3/frontbase/ibm_db/sqlserv
er/jdbcmysql/jdbcsqlite3/jdbcpostgresql/jdbc)
# Default: sqlite3
-j, [--javascript=JAVASCRIPT] # Preconfigure for sele
cted JavaScript library
# Default: jquery
-J, [--skip-javascript], [--no-skip-javascript] # Skip JavaScript files
[--dev], [--no-dev] # Setup the application
with Gemfile pointing to your Rails checkout
[--edge], [--no-edge] # Setup the application
with Gemfile pointing to Rails repository
-T, [--skip-test-unit], [--no-skip-test-unit] # Skip Test::Unit files
[--rc=RC] # Path to file containi
ng extra configuration options for rails command
[--no-rc], [--no-no-rc] # Skip loading of extra
configuration options from .railsrc file
Runtime options:
-f, [--force] # Overwrite files that already exist
-p, [--pretend], [--no-pretend] # Run but do not make any changes
-q, [--quiet], [--no-quiet] # Suppress status output
-s, [--skip], [--no-skip] # Skip files that already exist
Rails options:
-h, [--help], [--no-help] # Show this help message and quit
-v, [--version], [--no-version] # Show Rails version number and quit
Description:
The 'rails new' command creates a new Rails application with a default
directory structure and configuration at the path you specify.
You can specify extra command-line arguments to be used every time
'rails new' runs in the .railsrc configuration file in your home directory.
Note that the arguments specified in the .railsrc file don't affect the
defaults values shown above in this help message.
Example:
rails new ~/Code/Ruby/weblog
This generates a skeletal Rails installation in ~/Code/Ruby/weblog.
See the README in the newly created application to get going.
These are my Ruby and Rails versions(Ruby 2.0 and Rails 4.1.8):
C:\Users\Dav\Dropbox\Apps\Heroku\aqueous-waters-4632>ruby -v
ruby 2.0.0p598 (2014-11-13) [i386-mingw32]
C:\Users\Dav\Dropbox\Apps\Heroku\aqueous-waters-4632>rails -v
DL is deprecated, please use Fiddle
Rails 4.1.8
C:\Users\Dav\Dropbox\Apps\Heroku\aqueous-waters-4632>gem list
*** LOCAL GEMS ***
bundler (1.11.2)
jar-dependencies (0.1.15)
jruby-openssl (0.9.7 java)
jruby-win32ole (0.8.5)
json (1.8.0 java)
minitest (5.4.1)
power_assert (0.2.3)
psych (2.0.14.pre1 java)
rake (10.1.0)
rdoc (4.1.0)
ruby-maven (3.3.3)
ruby-maven-libs (3.3.3)
test-unit (3.0.3)
and finally this is heroku build log for reference(Ruby 2.2.2 and Rails 4.1.8):
-----> Using set buildpack heroku/ruby
-----> Ruby app detected
-----> Compiling Ruby/Rails
-----> Using Ruby version: ruby-2.2.2-jruby-9.0.0.0
-----> Installing JVM: openjdk-8
-----> Installing dependencies using bundler 1.9.7
Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
Using json 1.8.1
Using minitest 5.4.3
Using thread_safe 0.3.4
Using builder 3.2.2
Using erubis 2.7.0
Using rake 10.4.0
Using rack 1.5.2
Using i18n 0.6.11
Using mime-types 2.4.3
Using arel 5.0.1.20140414130214
Using coffee-script-source 1.8.0
Using jdbc-postgres 9.3.1102
Using execjs 2.2.2
Using thor 0.19.1
Using hike 1.2.3
Using multi_json 1.10.1
Using bundler 1.9.7
Using tilt 1.4.1
Using rails_serve_static_assets 0.0.2
Using rails_stdout_logging 0.0.3
Using sass 3.2.19
Using tzinfo 1.2.2
Using rdoc 4.1.2
Using mail 2.6.3
Using rack-test 0.6.2
Using puma 2.9.1
Using coffee-script 2.3.0
Using uglifier 2.5.3
Using rails_12factor 0.0.3
Using sprockets 2.12.3
Using activesupport 4.1.8
Using tzinfo-data 1.2015.1
Using sdoc 0.4.1
Using actionview 4.1.8
Using activemodel 4.1.8
Using jbuilder 2.2.5
Using actionpack 4.1.8
Using activerecord 4.1.8
Using actionmailer 4.1.8
Using sprockets-rails 2.2.2
Using railties 4.1.8
Using activerecord-jdbc-adapter 1.3.14
Using activerecord-jdbcpostgresql-adapter 1.3.14
Using coffee-rails 4.0.1
Using jquery-rails 3.1.2
Using rails 4.1.8
Using sass-rails 4.0.5
Using turbolinks 2.5.2
Bundle complete! 13 Gemfile dependencies, 48 gems now installed.
Gems in the groups development and test were not installed.
Bundled gems are installed into ./vendor/bundle.
Bundle completed (8.97s)
Cleaning up the bundler cache.
-----> Preparing app for Rails asset pipeline
Running: rake assets:precompile
Asset precompilation completed (13.25s)
Cleaning assets
Running: rake assets:clean
-----> Discovering process types
Procfile declares types -> web
Default types for buildpack -> console, rake, worker
-----> Compressing...
Done: 101.5M
-----> Launching...
Released v8
尝试运行bundle install
来安装您的gems,转到db / migrate并运行rake db:migrate
然后是rails s
。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.