-
Notifications
You must be signed in to change notification settings - Fork 365
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
Annoying executable reporting on NTFS drives in Linux #3949
Comments
I think it's probably feasible to have a mode where I'm surprised this is not more of a problem, actually. I'm guessing this might show up when using WSL as well. I can't decide whether this deserves a Windows tag, but I guess it ultimately does since it's Windows filesystems that don't have an executable bit. |
Sounds like we should replace the current compile-time switches between Windows and Unix by a runtime switch, which would then always be false on Windows and read from config on Unix. @wrzian, if you're interested in implementing it, see how it's currently done in https://github.com/martinvonz/jj/blob/main/lib/src/local_working_copy.rs. Just search for "executable" there. We would probably want to pass the config into |
Actually, that will make it harder to initialize it because we typically don't have the settings available when we want to initialize the |
FYI @ilyagr you're right, it is a big problem in WSL because the canonical way to access Windows OS files from WSL is via My guess is that most users don't mix WSL and Windows on a single repo. I certainly don't. |
I have a shared NTFS drive between Linux and Windows. In Linux I mount the NTFS drive with the 'exec' option (as default) so I can compile and run binaries. However 'exec' makes all files within the drive executable.
When I try to colocate a git repo on this drive, jj reports every file as being modified to be executable. While they all are executable, I don't want this represented as a change in the repo. Running
jj chmod normal <some_file>
does nothing because the drive is mounted with all files executable, and jj continues to report everything as modified to be executable.Git has an option for this as
core.fileMode
.Here is git's documentation:
https://git-scm.com/docs/git-config#Documentation/git-config.txt-corefileMode
core.fileMode
I'm not sure how an option like this might integrate with JJ's use of executable bits in windows, but it would be nice to add some solution for filesystems on Linux that can't easily control the executable bit.
The text was updated successfully, but these errors were encountered: