emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Tramp and `dired-listing-switches'


From: Emanuel Berg
Subject: Re: Tramp and `dired-listing-switches'
Date: Tue, 12 Dec 2023 21:15:40 +0100
User-agent: Gnus/5.13 (Gnus v5.13)

tomas wrote:

>>> I.e., /home/incal/public_html is actually
>>> /var/www/htdocs/dataswamp.org/~incal
>> 
>> I don't think so. "~incal" is the home directory of the
>> user "incal". But only, if "~incal" is the first part of
>> a file name.
>
> And only if you've told your web server to do this mapping
> for you (for Apache, it's mod_userdir and its config,
> lighttpd has a module with the same name, and I'm sure nginx
> has that too.
>
> It's the Web, so it's all smoke and mirrors.

Actually I just did

  $ file public_html
  public_html: symbolic link to '/var/www/htdocs/dataswamp.org/~incal'

so I don't know how/why it is setup like that. But it is!

But again that wasn't the issue anyway. (Actually it was the
second theory as to why it didn't work that I presented in
this thread, and both were incorrect LOL.)

I got it to work with the below code, so one can use it until
one upgrades Emacs and get the sanctioned, built-in solution.
Which also should be better.

(setq dired-listing-switches
  "-AGlX --group-directories-first -I \"*.meta\" -I \"#*#\" -I \"*.elc\"")

(add-hook 'dired-before-readin-hook
  (lambda ()
    (if (file-remote-p default-directory)
        (setq dired-actual-switches "-Al")
      (setq dired-actual-switches dired-listing-switches) )))

-- 
underground experts united
https://dataswamp.org/~incal




reply via email to

[Prev in Thread] Current Thread [Next in Thread]