简体   繁体   中英

How to clone my existing rails app

I have a rails app that on my local development machine and I want to copy it and have a sort of starting point in case I don't want to start over from scratch later for future projects. Is there a rails command I can use to "clone" it or should I simply copy and paste the directory?

There is no rails command to clone your app. But you can install git on your system and create a git repo to do what you want easily. To do this go to your rails app root and execute

git init
git add .
git commmit -m "Your commit message"

You can then continue working and commit your changes as needed or discard all or individual changes. You can also clone your app with the git clone commmand.

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.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM