enelesmai / odin-on-rails

How to start a Rails application guided by Odin Project

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

odin_on_rails

How to start a rails application guided by Odin Project, following git-flow and deployed to heroku.

Built With

  • Ruby 2.6.5
  • Rails 5.2.4
  • VSCode

Getting Started

The project was designed to create an scaffolded application with rails, following git-flow practices and deploying to heroku.

If you want to deploy this application to your heroku account follow the instructions in this link.

You need to know

  1. After heroku create you may need to add heroku as a remote source, use the following command:

    git remote add local-branch-name https://git.heroku.com/remote-app-123.git

    or

    heroku git:remote -a remote-app-123

Do this only if you don't see heroku in the output of the command git remote on your terminal. Visit Deploying with Git for more information.

  1. Heroku is by default working only with code commited to master, but there is a way to force it to take your non master branch. You can type:

    git push link-heroku-app local-branch:master

For more information on how to deploy to heroku visit the official Heroku documentation.

As an example, where https://git.heroku.com/afternoon-caverns-32087.git is the remote heroku repo and rails-app is your current branch, the next command should be typed to succesfully push to heroku:

git push https://git.heroku.com/afternoon-caverns-32087.git rails-app:master
  1. Finally, before pushing to heroku remember to remove .bundle folder so Heroku will create its own bundle when you push your code there, this is for fixing an issue like this one.

Running the program on local machine

Clone the repository to your local machine. To install gems run

bundle install

then run the server on https://localhost:3000

rails server 

Live Demo

image

Visit the live demo here.

Author

👤 Xóchitl Selene Flores Pérez

🤝 Contributing

Contributions, issues and feature requests are welcome!

Feel free to check the issues.

Show your support

Give a ⭐️ if you like this project!

About

How to start a Rails application guided by Odin Project


Languages

Language:Ruby 76.7%Language:HTML 15.9%Language:SCSS 2.8%Language:JavaScript 2.6%Language:CSS 1.5%Language:CoffeeScript 0.5%