gitignore - Git directories - how to track directories but not content -


i have .gitignore file so

.gitignore  /data* /node_modules/* /bower_components/* 

i want have directories pushed , pulled not contents of directory. above, directories ignored entirely. possible?

you can put .gitignore file in each directory want track without contents, , have contents (the .gitignore's file, is) *, ignore files in directory. git add .gitignore files , commit them. result should directories tracked (because of tracked .gitignore files in them), files in directories ignored.


Comments

Popular posts from this blog

python - mat is not a numerical tuple : openCV error -

c# - MSAA finds controls UI Automation doesn't -

wordpress - .htaccess: RewriteRule: bad flag delimiters -