1

Previously git project location was:

/e/dev/Project

New Git Project location:

/cygdrive/e/dev/Project

Is there any reason for changing path suddenly?

Does any one know what is cygdrive? I could find any documentation of cygdrive or reason for the above incident

Note:

Using GitBash Portable on windows10. I didn't install cygwin in my system purposefully.

Reason for Query: I am just vigilant about my recent system changes regarding my system safety

JOEL
  • 29
  • 7
  • 2
    You're giving us ambiguous tags: Are you in Cygwin, or in Git Bash? Those are not the same. I would expect `/e/...` in Git Bash, but `/cygdrive/e/...` in Cygwin. The latter is how Cygwin mounts your local drives in *its* bash shell. – joanis Dec 06 '22 at 23:38
  • 1
    Like _joanis_ suspects: You are not using _git bash_, but _git_ from cygwin. `/cygdrive` is the cygwin mount point for all windows drive letters; for instance, C:\ is `/cygdrive/c`. Is there a reason why you installed both, git-bash **and** cygwin? This is a somewhat odd setup. – user1934428 Dec 07 '22 at 12:02
  • 1
    Use the `where git` windows command and/or the `which -a git` cygwin command to find out which git you are using at any time. It is possible that you are using a different git when you work in a windows cmd shell vs when you are in a cygwin bash shell due to order of folders in the shell's paths. – Doug Henderson Dec 07 '22 at 19:13
  • @DougHenderson, `which -a git` gives `/mingw64/bin/git` – JOEL Dec 07 '22 at 20:17
  • @user1934428, I didn't install cygwin, It might be some software addons – JOEL Dec 07 '22 at 20:19
  • As per my current understanding, it is a part of git bash, so there is no security thread I guess. I will use cygdrive as the prefix. – JOEL Dec 07 '22 at 20:26
  • @joanis Previously it was correct, Suddenly it changes. Earlier I changed `etc/profile` . It was working, Now the changes are not reflecting due to this issue. I am just vigilant about recent system changes for system safety. – JOEL Dec 07 '22 at 20:38
  • It's odd that it should change all of a sudden, but from a security perspective, I agree with your conclusion that it's ok, you're still looking at the same E: drive. The command `mount` will also give you positive confirmation, telling you exactly where each drive is mounted in the Bash view. – joanis Dec 07 '22 at 22:15
  • 1
    If you did not install Cygwin by yourself, and it had been installed by some other sofware, you are probably in trouble. I won't say that you can't use Cygwin **and** git bash on the same platform, but if this were my machine, I would first find out which rogue application installs Cygwin without telling me. If you want to keep both on your computer, maybe it is the best that you set up different environments, where you use only one but not the other. In this case, I think it would make sense to delete Git bash and stick with Cygwin, but it's your choice after all. – user1934428 Dec 09 '22 at 14:05
  • @user1934428, I couldn't find any Cygwin or related apps in the Control panel. Anyway, I will check root cause. **Thanks for the advice** – JOEL Dec 10 '22 at 14:14
  • I wouldn't search in the control panel for this, simply because there is no reason why cygwin would show up there. I would search your harddisk for, say, a command `cygpath.exe` or, more general, any file matching `cyg*.exe`. – user1934428 Dec 11 '22 at 08:44

1 Answers1

1

Depending on your Git version, cypath is supported, and would convert /cygdrive/e/dev/Project into /e/dev/Project in a regular Git For Windows bash.

So check what has changed between the time when the path was reported as /e, and now where it is reported as /cygdrive.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250