9

When visiting a directory: In the view that comes up, I want the file/directory names to be in the left-most column. How can I do that?

4
  • This is not entirely clear: by default find-file will prompt you to choose a file but there is no view with columns. Are you perhaps asking about the directory listing you get after using C-x C-f to open a directory? That would be a question about dired. Commented Dec 8, 2017 at 16:10
  • you are correct, i am asking about the directory listing that comes up Commented Dec 8, 2017 at 16:24
  • OK, I've revised the question and tags a bit to make that clear. I've offered my own answer but perhaps others will have some suggestions on getting the display you want. Commented Dec 8, 2017 at 16:27
  • 1
    Please make clear in the question that you do not care whether any other columns are shown, besides the file name. There is a big difference between showing only file names and rearranging the column order. Emacs provides the first but not the second. Commented Dec 8, 2017 at 18:46

2 Answers 2

17

Assuming this question is about dired (the Emacs directory editor mode), there is no simple built-in way to rearrange the columns. Dired is presenting the output of an ls command so you can customize dired-listing-switches if there are ls output options that you prefer.

You can also switch to a very simple dired view by using the key ( in a dired buffer -- this is bound by default to the command dired-hide-details-mode, which will drop all the columns and just show the file names.

Beyond that I believe you would need to look for an optional package or write some elisp yourself to build a custom directory view.

You can learn more about Dired in the Emacs manual (online, or use C-h i to browse the manuals in Emacs itself.)

0
0

This package does it.

https://github.com/misohena/dired-details-r

However it is quite slow. If you don't want to see the details, maybe just use (scroll-left 20) in dired buffer.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.