protesilaos • 5y ago Dired is fantastic! To add a bit to what the previous user documented: Mark some files with m and hit k to temporarily remove them from your view (g to refresh and bring them back). When no mark is active, m will mark everything. t toggles the mark. So you can, e.g., mark three files, toggle the mark, then k, to just limit the list to those three. Marking can be done with regular expressions. Hit % C-h inside a Dired buffer to list all commands at your disposal. Also try * C-h for more relevant commands. w copies a file's name. 0 w (C-u 0 w) copies the full path. Works with multiple marked items as well, separating them with a space. You can run keyboard macros that move between a Dired window and another buffer. So you could, e.g. copy filesystem paths, edit them accordingly, and move to the next step (and kmacros are a powerhouse in their own right). Use Z to compress or uncompress. With Q you can query-replace (regexp) through all the marked files. Remember that in a query prompt ! means "yes to all". With ! in Dired you can run any shell command on the marked files. With & you run the command in the background (same as in the terminal emulator). dired-jump will take you to the directory that contains the current buffer. From inside Dired, it will move up a directory. find-name-dired will produce a Dired buffer while using the CLI find command. Combine that with all the aforementioned possibilities. Same principle for find-grep-dired. I probably forgot several of them. No worries: C-h m will produce a help buffer with information about the major mode you are in, as well as all minor modes that are active.
2 Matching Annotations
- Aug 2025
-
www.reddit.com www.reddit.com
-
- Aug 2023
-
emacs.ch emacs.ch
-
dired-toggle-read-only (usually bound to "C-x C-q"), now the Dired buffer is editable — you can change the names of files and later choose to commit those changes to disk use occur (usually bound to "M-s o") to narrow down the listed files in the Dired buffer , then use occur-edit-mode in the Occur buffer, use occur-edit-mode (bound to the "e" key) to make the occur buffer editable Use any number of query-replace ("M-%") or query-replace-regexp ("C-M-%") to rename any of the files in the Occur buffer. occur-cease-edit ("C-c C-c") to commit changes from the Occur buffer to the Dired buffer wdired-finish-edit (also bound to "C-c C-c") to commit those changes in the Dired buffer to the filesystem.
dired내에서 occur를 통해 필터링을 한 뒤에 검색을 하는 등의 수정작업을 진행한 후 변경사항을 반영할 수 있다.
Tags
Annotators
URL
-