No such file or directory found - git bash

223 Views Asked by At

error coming by cd filename

prakh@Prakhar11 MINGW64 ~ (main) $ cd C:\Users\prakh\OneDrive\Desktop\github\my-github\src\app bash: cd: C:UsersprakhOneDriveDesktopgithubmy-githubsrcapp: No such file or directory

trying to add file in github and push it

1

There are 1 best solutions below

0
On

Try replacing the backslashes (\) with forward slashes (/): and try this

cd /c/Users/prakh/OneDrive/Desktop/github/my-github/src/app

Also The /c/ at the beginning of the path is used in Git Bash to specify the C:\ drive in Windows.

Also, ensure that the directory app exists under C:\Users\prakh\OneDrive\Desktop\github\my-github\src\. If you still get a "No such file or directory" error, the path might be wrong or the directory might not exist.