|
From: | Jürgen Hötzel |
Subject: | Re: tramp-gvfs: parsing issues when using locale |
Date: | Wed, 21 Oct 2015 23:48:56 +0200 |
Jürgen Hötzel <address@hidden> writes:
> Hi Michael.
Hi Jürgen,
> (Yes, the method name is not agreed yet between us ...)
>
> I don't mind having this shorter method. I personaly just don't need
> it (because I use completion anyway).
> I thought this new method name might just confuse some users and short
> method names might get confusing too if other backends will be added
> (OneDrive -> od)?
In case we don't agree, let's add both method names :-)
Seriously: You implement, you decide.
> I have enclosed a patch (nothing ready to merge yet).
If I run tramp-tests.el, it fails tramp-test32-utf8. Maybe you can have
a look on it. If it passes that test suite, no problem from my side to
commit the patch for further work. Some words in tramp.texi would also
be appreciated.
My private test uses my GMX account and the related mediacenter disk space:
--8<---------------cut here---------------start------------->8---
env REMOTE_TEMPORARY_FILE_DIRECTORY=/davs:address@hidden@mediacenter.gmx.net:/Sonstige\ Dateien \
make check
...
Ran 42 tests, 27 results as expected, 1 unexpected, 14 skipped (2015-10-19 11:37:44+0200)
1 expected failures
1 unexpected results:
FAILED tramp-test32-utf8
I'm curious: how does Nautilus handle the problem? What is shown as file
name, just the display-name, or blob-id, or both? What does it show as
"Properties" of such a file?
> Also there is some room for optimization (calling gvfs-info once for
> the whole directory list, instead for each entry).
Of course. I vaguely remember that I wanted to add this years ago; this
idea has been lost somehow. And likely, there are other glitches in
tramp-gvfs.el you will find.
Just some few remarks on the patch:
> +(defun tramp-gvfs-handle-file-attributes (filename &optional id-format)
> + "Like `file-attributes' for Tramp files."
> + (unless id-format (setq id-format 'integer))
> + (ignore-errors
> + ;; Don't modify `last-coding-system-used' by accident.
Nitpicking: Comment superfluous.
> + ;; ... inode and device
> + (setq res-inode
> + (let ((n (cdr (assoc "unix::inode" attributes))))
> + (if n (string-to-number n)
> + (tramp-get-inode v))))
> + (setq res-device
> + (let ((n (cdr (assoc "unix::device" attributes))))
> + (if n (string-to-number n)
> + (tramp-get-device v))))
Here I get a compilation warning. Change it to
(tramp-get-inode (tramp-dissect-file-name filename)))))
(tramp-get-device (tramp-dissect-file-name filename)))))
or similar.
> @@ -986,6 +990,13 @@ file names."
> (goto-char (point-max))
> (while (zerop (forward-line -1))
> (setq entry (buffer-substring (point) (point-at-eol)))
> + ;; use display-name if available (google-drive)
Nitpicking: Start comments with a capital letter. Finish them with a period.
[Prev in Thread] | Current Thread | [Next in Thread] |