4

I then tried various sorts of C-h and websearch, without success. Please check the manual first! (or second, after docstrings) (eshell) Dollars Expansion: Eshell has different ‘$’ expansion syntax from other shells. There are some similarities, but don’t let these lull you into a false sense of familiarity. [...] ‘${command}’ Returns the output of ‘...


3

To answer your question about find-name-dired, according to its manual page (C-h f find-name-dired): The default command run (after changing into DIR) is find . -name 'PATTERN' -ls See ‘find-name-arg’ to customize the arguments. If you go to find-name-arg manual page, you get: find-name-arg is a variable defined in ‘find-dired.el’. Its value is "-...


3

After doing some googling for the Linux find parameters and looking at the find-dired function, I came with these two functions that seem to work. Not sure if this is the optimal way, but at least they have the effect I desired: (defun find-dired-by-date (dir args) (interactive (list (read-directory-name "Run find in directory: " nil "" t) ...


3

tl;dr Do you get the expected behavior under emacs -Q? It's possible you've disabled case-insensitivity. Long answer Without knowing your arguments to find-name-dired (you should add them to your question) it's hard to say. If you included the double quotes, Emacs will escape them and find will look for files that include them. Based on your output that ...


2

sftp is implemented in Tramp by GVFS, so it doesn't support remote processes. You must use a Tramp method like ssh or scp.


1

This really has nothing to do with find-name-dired. This is about Q in Dired buffers (including from find-name-dired). Q is dired-do-find-regexp-and-replace. That command treats your first input pattern as a regexp. And . in a regexp matches any character except newline. What you want to use, instead of .value, is [.]value. That is, you want a pattern ...


1

@phils answered the question. This is just to say that the version of find-grep-dired in library find-dired+.el provides a bit more than the vanilla version: It has two optional args, DEPTH-LIMITS and EXCLUDED-PATHS. The interactive spec uses read-from-minibuffer, read-file-name, dired-regexp-history and find-diredp-default-fn. find-grep-dired is an ...


1

The following does that and presents the results as a dired buffer: M-x find-grep-dired You'll also want to know about: M-x rgrep (which doesn't support the -l option to grep, but is usually what I want from a recursive regexp search.)


1

You can use the ls command of the built-in eshell for listing the files with some predefined depth. You have to specify the depth by the right number of concatenated file name generator expressions */. Example: (split-string (substring-no-properties (eshell-command-result "ls /usr/share/emacs/26.1/*/*/*/*/*/*(.)") ) "\n" t) The appended modifier (.)...


1

Library find-dired+.el can help with this. C-h f find-dired: find-dired is an interactive compiled Lisp function in find-dired+.el. (find-dired DIR ARGS &optional DEPTH-LIMITS EXCLUDED-PATHS) Run find and put its output in a buffer in Dired Mode. Then run find-dired-hook and dired-after-readin-hook. The find’ command run (after ...


1

The elgrep-search command has options :mindepth and :maxdepth. Elgrep is available via package-install from the melpa package archive (instructions how to add melpa to package-archives can be found on the melpa "Getting Started" page). You can use elgrep as follows to get a list of matching file names of a specific depth. In the example I search in my HOME-...


1

I'd be inclined to use find for that: (let ((dirname (expand-file-name "~/")) (depth 3)) (split-string (shell-command-to-string (format "find %s -mindepth %d -maxdepth %d -type d -print0 2>/dev/null" (shell-quote-argument dirname) depth depth)) "\0" :omit-nulls)) n.b. -mindepth, -maxdepth, and print0 are not POSIX options, ...


1

If you use library find-dired+.el then you can do the date part using command find-time-dired: find-time-dired is an interactive compiled Lisp function. (find-time-dired DIR MIN-TIME MAX-TIME &optional DEPTH-LIMITS EXCLUDED-PATHS) Find files in directory DIR newer or older than a timestamp. The output is shown in a Dired buffer. ...


1

I solved the problem by defining this function + shortcut: (defun find-in-current-location () (interactive) (find-dired dired-directory (concat "-iname \"*" (read-from-minibuffer "Search for: ") "*\""))) (global-set-key (kbd "C-c f") 'find-in-current-location)


1

OK, found the problem: I also had to set shell-file-name to something other than /bin/sh, because Ubuntu ships with Dash as sh and Emacs relies on non-standard GNU features present in Bash, but not Dash.


Only top voted, non community-wiki answers of a minimum length are eligible