-
-
Notifications
You must be signed in to change notification settings - Fork 578
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
[#1148] Don't show deleted files in listing #1825
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -672,11 +672,36 @@ means check all the subdirectories of DIRECTORY. Etc." | |
:type '(repeat (choice directory (cons directory (integer :tag "Depth")))) | ||
:package-version '(projectile . "1.0.0")) | ||
|
||
(defcustom projectile-fd-executable | ||
(cond | ||
((executable-find "fdfind") "fdfind") | ||
((executable-find "fd") "fd")) | ||
"Path or name of fd executable used by Projectile if enabled. | ||
Nil means fd is not installed or should not be used." | ||
:type 'string) | ||
raxod502 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
(defcustom projectile-git-use-fd (when projectile-fd-executable t) | ||
"Non-nil means use fd to implement git ls-files. | ||
This may change Projectile's performance in large Git repositories | ||
depending on your system, but it will also work around the Git behavior | ||
that causes deleted files to still be shown in Projectile listings until | ||
their deletions are staged." | ||
:type 'boolean | ||
:package-version '(projectile . "2.8.0")) | ||
|
||
(defcustom projectile-git-command "git ls-files -zco --exclude-standard" | ||
"Command used by projectile to get the files in a git project." | ||
:group 'projectile | ||
:type 'string) | ||
|
||
(defcustom projectile-git-fd-args "-H -0 -E .git -tf --strip-cwd-prefix" | ||
"Arguments to fd used to re-implement `git ls-files'. | ||
This is used with `projectile-fd-executable' when `projectile-git-use-fd' | ||
is non-nil." | ||
:group 'projectile | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This one should have a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sorry, b68f7ef |
||
:type 'string | ||
:package-version '(projectile . "2.8.0")) | ||
|
||
(defcustom projectile-git-submodule-command "git submodule --quiet foreach 'echo $displaypath' | tr '\\n' '\\0'" | ||
"Command used by projectile to list submodules of a given git repository. | ||
Set to nil to disable listing submodules contents." | ||
|
@@ -1422,7 +1447,12 @@ IGNORED-DIRECTORIES may optionally be provided." | |
"Determine which external command to invoke based on the project's VCS. | ||
Fallback to a generic command when not in a VCS-controlled project." | ||
(pcase vcs | ||
('git projectile-git-command) | ||
('git (if (and projectile-git-use-fd projectile-fd-executable) | ||
(concat | ||
projectile-fd-executable | ||
" " | ||
projectile-git-fd-args) | ||
projectile-git-command)) | ||
('hg projectile-hg-command) | ||
('fossil projectile-fossil-command) | ||
('bzr projectile-bzr-command) | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd also make a note of this in the docs (probably somewhere in usage and in the FAQ).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
e49fee4
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just realized there is a separate usage page apart from the readme. It already says fd is used when possible and installed, shall I add more detail about how Projectile determines which tool to use?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I guess that'd be a nice addition to the docs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
b68f7ef