Git Gotcha: How to Commit Empty Folders with Ease

So you’re in the same situation as me, right? You have some empty folders that you don’t have content for yet, but you want to commit them and make them available on your remote repository.

Well, you can easily achieve this by creating a .gitkeep file…


This content originally appeared on DEV Community and was authored by Olusola Amoo

So you’re in the same situation as me, right? You have some empty folders that you don’t have content for yet, but you want to commit them and make them available on your remote repository.

Well, you can easily achieve this by creating a .gitkeep file in each of the folders.

When you commit, changes get included. When you push, they get pushed too.

Image description


This content originally appeared on DEV Community and was authored by Olusola Amoo


Print Share Comment Cite Upload Translate Updates
APA

Olusola Amoo | Sciencx (2024-07-04T21:21:58+00:00) Git Gotcha: How to Commit Empty Folders with Ease. Retrieved from https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/

MLA
" » Git Gotcha: How to Commit Empty Folders with Ease." Olusola Amoo | Sciencx - Thursday July 4, 2024, https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/
HARVARD
Olusola Amoo | Sciencx Thursday July 4, 2024 » Git Gotcha: How to Commit Empty Folders with Ease., viewed ,<https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/>
VANCOUVER
Olusola Amoo | Sciencx - » Git Gotcha: How to Commit Empty Folders with Ease. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/
CHICAGO
" » Git Gotcha: How to Commit Empty Folders with Ease." Olusola Amoo | Sciencx - Accessed . https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/
IEEE
" » Git Gotcha: How to Commit Empty Folders with Ease." Olusola Amoo | Sciencx [Online]. Available: https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/. [Accessed: ]
rf:citation
» Git Gotcha: How to Commit Empty Folders with Ease | Olusola Amoo | Sciencx | https://www.scien.cx/2024/07/04/git-gotcha-how-to-commit-empty-folders-with-ease/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.