I am working on a data analysis project whose directory structure looks like following
pipeline1.py
pipeline2.py
...
pipelineN.py
data/
config/
test/
where folder data/
mixes a lot of data processing Python scripts and raw data.
Now I am almost done with the data preprocessing in data/
and ready to commit changes to my personal GitHub repo. However, I am not sure how could I push only .py
in this folder.
I have tried adding following to .gitignore
but this will ignore the data/
entirely and hence not desirable.
!*.py
data/
question from:
https://stackoverflow.com/questions/65862018/only-push-files-with-certain-extensions-to-github 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…