简体   繁体   中英

Adding Folder/Subfolders/files in Git

How can I add a folder recursively, with its subfolders and its files?

When I use git add folder_name , only that folder is getting added. git status now shows the files under the subfolders are shown as new files and untracked.

For example, in Rails application, inside the Rails project folder, there are many folders:

  • app
  • public
  • db
  • script
  • vendor
  • etc.

Is there a better way to add a rails project to git?

cd desired_directory; git add .;

,看来我在打字时,贾斯汀·L。(Justin L.)在评论中回答了这个问题。

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