Reputation: 6819
env:
I copy the .git directory of Android goldfish kernel repo from Ubuntu to Windows, result in git status
is:
# On branch android-goldfish-2.6.29
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: Documentation/io-mapping.txt
# modified: arch/ia64/scripts/check-gas
# modified: arch/ia64/scripts/toolchain-flags
# modified: arch/powerpc/boot/wrapper
# modified: drivers/mmc/core/sdio_io.c
# modified: include/linux/earlysuspend.h
# modified: include/linux/mmc/sdio_func.h
# modified: include/linux/netfilter/xt_connmark.h
# modified: include/linux/netfilter/xt_dscp.h
# modified: include/linux/netfilter/xt_mark.h
# modified: include/linux/netfilter/xt_rateest.h
# modified: include/linux/netfilter/xt_tcpmss.h
# modified: include/linux/netfilter_ipv4/ipt_connmark.h
# modified: include/linux/netfilter_ipv4/ipt_dscp.h
# modified: include/linux/netfilter_ipv4/ipt_ecn.h
# modified: include/linux/netfilter_ipv4/ipt_mark.h
# modified: include/linux/netfilter_ipv4/ipt_tcpmss.h
# modified: include/linux/netfilter_ipv4/ipt_tos.h
# modified: include/linux/netfilter_ipv4/ipt_ttl.h
# modified: include/linux/netfilter_ipv6/ip6t_hl.h
# modified: include/linux/netfilter_ipv6/ip6t_mark.h
# modified: include/linux/wakelock.h
# modified: net/ipv4/netfilter/ipt_ecn.c
# modified: net/ipv4/netfilter/ipt_ttl.c
But I haven't modefied any fiels, and git checkout -- .
doesn't work, it still prompt the information. So what's the problem?
Thanks!
Upvotes: 1
Views: 213
Reputation: 120
The modification must be by the end of line, differ in windows and linux.
When you are using GitExtensions this process is automatically. But commit this changes should not affect your project.
You can read more about it on github documentation eventually, you can use the solution that exposes, this solution was response in SO
Upvotes: 0
Reputation: 5263
There is no need to copy paste .git folder. Setup git again in ubuntu or windows where you want to copy the code. Add remote origin and pull your code first. If you don't have remote origin then first push your code in some remote repo like github or bitbucket. I also did it with my projects.
Upvotes: 2