I'm trying to do a sparse checkout on an existing project with a whole repository checked out. The current structure is
database/ htdocs/ include/
But I only want include and certain folders from the htdocs directory.
So did the following:
git config core.sparsecheckout true
vi .git/info/sparse-checkout
and I entered
include
htdocs/*
!htdocs/downloads
!htdocs/images
!htdocs/videos
This worked in my testing environmen with git version git version 1.7.12.4 (Apple Git-37) but doesn't on an Ubuntu machine with git version 1.7.0.
On my server the whole include folder got deleted and on git pull it says everthing is up to date.
What am I missing here?