1. For example, a new Ruby on Rails project named toy_app is created using Linux shell terminal:
$ cd ~
$ rails _5.0.1_ new toy_app
$ cd toy_app/
2. (Optional): Install local Gem without production:
$ bundle install --without production
3. Put the Rails project under version control with Git:
$ git init
$ git add -A
$ git commit -m "Initialize repository"
4. In Firefox, go to Github https://github.com/YourGithubAccount/
- Login to your Github account (e.g. https://github.com/jimmy2046/)
- On the top-right corner -> click the plus (+) button
- Click New repository
5. In the Github's Create a new repository windows:
- Give a repository name (e.g. toy_app)
- (Optional): Write a Description if you like
- Public repository is free of charge as of the time of writing
- Click the Create repository button
6. In the repository setup windows, I selected the push an existing repository from the command line method:
- In Linux shell terminal:
$ git remote add origin https://github.com/jimmy2046/toy_app.git
$ git push -u origin master
7. Done. A new Ruby on Rails project is pushed to Github.
No comments:
Post a Comment