0
0
Ruby on Railsframework~10 mins

Rails new project generation - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to create a new Rails project named 'blog'.

Ruby on Rails
rails [1] blog
Drag options to blanks, or click blank then click option'
Astart
Bgenerate
Cnew
Dcreate
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'rails generate' instead of 'rails new'.
Using 'rails create' which is not a valid command.
Using 'rails start' which does not create a project.
2fill in blank
medium

Complete the code to create a new Rails project without installing gems immediately.

Ruby on Rails
rails new blog [1]
Drag options to blanks, or click blank then click option'
A--skip-gemfile
B--skip-bundle
C--no-install
D--no-gems
Attempts:
3 left
💡 Hint
Common Mistakes
Using '--no-install' which is not a valid option.
Using '--skip-gemfile' which does not exist.
Using '--no-gems' which is invalid.
3fill in blank
hard

Fix the error in the command to create a new Rails project with PostgreSQL as the database.

Ruby on Rails
rails new blog -d [1]
Drag options to blanks, or click blank then click option'
Apostgresql
Bmysql
Csqlite
Dmongo
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'mysql' which is a different database.
Using 'sqlite' which is the default but not PostgreSQL.
Using 'mongo' which is not supported by default.
4fill in blank
hard

Fill both blanks to create a new Rails project named 'shop' with API mode and skip test files.

Ruby on Rails
rails new shop [1] [2]
Drag options to blanks, or click blank then click option'
A--api
B--skip-test
C--skip-test-unit
D--skip-tests
Attempts:
3 left
💡 Hint
Common Mistakes
Using '--skip-test' which is not a valid option.
Using '--skip-tests' which is invalid.
Confusing API mode option with database option.
5fill in blank
hard

Fill all three blanks to create a new Rails project named 'forum' with PostgreSQL, skip Action Mailbox, and skip Action Text.

Ruby on Rails
rails new forum -d [1] [2] [3]
Drag options to blanks, or click blank then click option'
A--skip-action-mailbox
B--skip-action-text
Cpostgresql
D--skip-active-storage
Attempts:
3 left
💡 Hint
Common Mistakes
Using '--skip-active-storage' instead of skipping mailbox or text.
Mixing up the order of options.
Using 'mysql' instead of 'postgresql' for the database.