Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

warning: unable to access '.gitignore': Too many levels of symbolic links #43

Closed
rjc opened this issue Jun 30, 2021 · 4 comments
Closed

Comments

@rjc
Copy link

rjc commented Jun 30, 2021

I get the above warning after running git status:

$ git status
warning: unable to access '.gitignore': Too many levels of symbolic links
On branch master
Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean

Indeed, it seems a bit convoluted:

$ ls -l .gitignore 
lrwxr-xr-x  1 foo  bar  16 Mar 22 16:12 .gitignore -> shared/gitignore
$ ls -l shared 
lrwxr-xr-x  1 foo  bar  16 Mar 22 16:12 shared -> notebooks/shared

Any chance to simplify things in order to get rid of the warning?

@rjc
Copy link
Author

rjc commented Jul 13, 2021

Ping.

@andreas-zeller
Copy link
Member

Hi @rjc - I don't see this message, but I removed one level of symbolic links for .gitignore. Are things better now?

@rjc
Copy link
Author

rjc commented Jul 20, 2021

From what I can see, you've merely edited the .gitignore file. The issue seems to be the fact that .gitignore itself is a symbolic link:

$ git clone https://github.com/uds-se/debuggingbook.git
Cloning into 'debuggingbook'...
warning: object 0d78b95a4b40ed320caa2abe948790cb26f3a709: gitignoreSymlink: .gitignore is a symlink
# the above line repeated 2709 times with different object IDs
Updating files: 100% (1426/1426), done.

Not sure how can you not see this. Which version of Git are you using?

$ git --version
git version 2.32.0

@andreas-zeller
Copy link
Member

Thanks! I have now made .gitignore a regular file, updated from shared/gitignore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants