[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#47247: 28.0.50; read-file-name: should display slash correctly in th
From: |
Michael Albinus |
Subject: |
bug#47247: 28.0.50; read-file-name: should display slash correctly in the prompt |
Date: |
Fri, 19 Mar 2021 09:04:50 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Eli Zaretskii <eliz@gnu.org> writes:
>> When I do this:
>>
>> (read-file-name "File name for export: " (getenv "HOME") nil nil (concat
>> "Location-Set-ID-" "731" ".gpx"))
>>
>> The file name in the prompt s displayed as:
>>
>> File name for export: ~Location-Set-ID-731.gpx
>>
>> without slash, rather than as:
>>
>> File name for export: ~/Location-Set-ID-731.gpx
>
> That's a cockpit error: you should run the directory through
> expand-file-name if you want to use (getenv "HOME") in that context.
Likely, it's not sufficient:
(expand-file-name "~") => "/home/albinus"
Better, run it through file-name-as-directory.
Best regards, Michael.