I am trying to do a sparse checkout without shallo clone. I am able to do this successfully. But the problem is, when I do, the entire folder structure is being created.
For example:
I am trying to clone the subdirectory at the path:reponame/path/to/the/directory
To the local folder: local_dir
Now after the sparse checkout, the content of the local_dir is like below:
local_dir/path/to/the/directory
But I need the content from the folder directory
to come directly under local_dir
. How do I do this?
Side note: I am trying to do this for a golang project. I need to put the golang project inside an already existing repo under a specific directory structure. So if you have any tips on how to do this, please do let me know. I can't put the entire content of the repo inside the go's working dir path.