* cpio-mode @ 2018-02-02 4:14 Douglas Lewan 2018-02-02 13:48 ` cpio-mode Michael Albinus 0 siblings, 1 reply; 4+ messages in thread From: Douglas Lewan @ 2018-02-02 4:14 UTC (permalink / raw) To: emacs-devel [-- Attachment #1: Type: text/plain, Size: 593 bytes --] All, Two or three years ago I joined this mailing list and announced that I wanted to write a cpio mode for emacs. Well, after various surprising events and mishaps I'm back, and expect to have something worth showing soon. What is the customary way of sharing such code? I'm currently working under CVS on my local box and expect to continue doing my detailed work there, but if there's a preferred way to share, then I'd like to integrate that. Thanks. -- ,Doug Douglas Lewan (908) 720-7908 What one programmer can do in one month, two programmers can do in two months. -- Fred Brooks [-- Attachment #2: Type: text/html, Size: 896 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cpio-mode 2018-02-02 4:14 cpio-mode Douglas Lewan @ 2018-02-02 13:48 ` Michael Albinus 2018-02-02 15:47 ` cpio-mode Douglas Lewan 0 siblings, 1 reply; 4+ messages in thread From: Michael Albinus @ 2018-02-02 13:48 UTC (permalink / raw) To: Douglas Lewan; +Cc: emacs-devel Douglas Lewan <d.lewan2000@gmail.com> writes: > All, Hi Doug, > Two or three years ago I joined this mailing list and announced that I > wanted to write a cpio mode for emacs. > > Well, after various surprising events and mishaps I'm back, and expect > to have something worth showing soon. Time passes, and I have committed tramp-archive.el to Emacs' master branch, which supports also cpio archives (read-only for now). See <http://lists.gnu.org/archive/html/emacs-devel/2017-12/msg00263.html>. Could you pls compare this with your work? > Thanks. Best regards, Michael. ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cpio-mode 2018-02-02 13:48 ` cpio-mode Michael Albinus @ 2018-02-02 15:47 ` Douglas Lewan 2018-02-02 16:30 ` cpio-mode Michael Albinus 0 siblings, 1 reply; 4+ messages in thread From: Douglas Lewan @ 2018-02-02 15:47 UTC (permalink / raw) To: Michael Albinus; +Cc: emacs-devel [-- Attachment #1: Type: text/plain, Size: 2971 bytes --] Michael, First: Oh, my! I've been reading about a missing cpio mode in the emacs TODO file for years, I'd sort of assumed that there was little work on it. (I do admit that when I'd last joined this list, I did receive a few attempts to start such a project.) Your work sounds similar to mine. Indeed, my goal is to write something like a dired front end to all the cpio formats, with relatively easy extensibility to others. This should include editing, adding and deleting archive members. That's turned out to be a little more than I was expecting. Once I started looking more closely, dired is much larger that I was expecting. FYI The design is coarsely given in this diagram. ;; +----------------------+ +-------------+ +-------------+ ;; | Format specific code | | | | | ;; | +---------------+ | | | | | ;; | | cpio-bin | | | | | | ;; | | +--------------+ | | CPIO | | dired-like | ;; | +-|cpio-crc | |<->| Logic |<->| UI | ;; | | +-------------+ | | | | | ;; | +-| hpbin | | | | | | ;; | | +------------+ | | | | | ;; | +-| ··· | | | | | | ;; | +------------+ | | | | | ;; +----------------------+ +-------------+ +-------------+ ;; Λ Λ Λ ;; | | | ;; V V V ;; +----------------------------------------------------------+ ;; | generic code | ;; | +------------+ +--------------+ +-----+ | ;; | | cpio-modes | | cpio-generic | | ··· | | ;; | +------------+ +--------------+ +-----+ | ;; +----------------------------------------------------------+ Could you point me to your code? Thanks. On Fri, Feb 2, 2018 at 8:48 AM, Michael Albinus <michael.albinus@gmx.de> wrote: > Douglas Lewan <d.lewan2000@gmail.com> writes: > > > All, > > Hi Doug, > > > Two or three years ago I joined this mailing list and announced that I > > wanted to write a cpio mode for emacs. > > > > Well, after various surprising events and mishaps I'm back, and expect > > to have something worth showing soon. > > Time passes, and I have committed tramp-archive.el to Emacs' master > branch, which supports also cpio archives (read-only for now). See > <http://lists.gnu.org/archive/html/emacs-devel/2017-12/msg00263.html>. > > Could you pls compare this with your work? > > > Thanks. > > Best regards, Michael. > -- ,Doug Douglas Lewan (908) 720-7908 What one programmer can do in one month, two programmers can do in two months. -- Fred Brooks [-- Attachment #2: Type: text/html, Size: 5237 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cpio-mode 2018-02-02 15:47 ` cpio-mode Douglas Lewan @ 2018-02-02 16:30 ` Michael Albinus 0 siblings, 0 replies; 4+ messages in thread From: Michael Albinus @ 2018-02-02 16:30 UTC (permalink / raw) To: Douglas Lewan; +Cc: emacs-devel Douglas Lewan <d.lewan2000@gmail.com> writes: > Michael, Hi Doug, > First: Oh, my! I've been reading about a missing cpio mode in the > emacs TODO file for years, I'd sort of assumed that there was little > work on it. (I do admit that when I'd last joined this list, I did > receive a few attempts to start such a project.) I haven't updated the TODO file yet, so you wouldn't still know it ... > Your work sounds similar to mine. Indeed, my goal is to write > something like a dired front end to all the cpio formats, with > relatively easy extensibility to others. That fits perfectly. I have written a *back end*, based on the file name handler approach of Emacs. See (info "(elisp) Magic File Names") In fact, most of the basic operations mentioned there got a new implementation in file .../lisp/net/tramp-archive.el. You don't need to configure anything in your Emacs, those alternative implementations come into play based on the file name. Just open the virtual file "/path/to/file.cpio/", and you have a dired buffer with the contents of the archive. Call (copy-file "/path/to/file.cpio/foo" "/tmp") etc pp. I have written something about in the Tramp manual, check (info "(tramp) Archive file names") There are also test cases which could give you an impression what's possible, see .../test/lisp/net/tramp-archive-tests.el. This implementation has some limitations, though. It is based on GVFS, the Gnome Virtual File System. In practice, it works only for GNU/Linux systems. Another drawback is, that the Gnome folks haven't implemented write access for archives, although it would be possible. Here I'm still a little bit undecided how to continue. > This should include editing, > adding and deleting archive members. That's turned out to be a little > more than I was expecting. Once I started looking more closely, dired > is much larger that I was expecting. > > FYI The design is coarsely given in this diagram. > > ;; +----------------------+ +-------------+ +-------------+ > ;; | Format specific code | | | | | > ;; | +---------------+ | | | | | > ;; | | cpio-bin | | | | | | > ;; | | +--------------+ | | CPIO | | dired-like | > ;; | +-|cpio-crc | |<->| Logic |<->| UI | > ;; | | +-------------+ | | | | | > ;; | +-| hpbin | | | | | | > ;; | | +------------+ | | | | | > ;; | +-| ··· | | | | | | > ;; | +------------+ | | | | | > ;; +----------------------+ +-------------+ +-------------+ > ;; Λ Λ Λ > ;; | | | > ;; V V V > ;; +----------------------------------------------------------+ > ;; | generic code | > ;; | +------------+ +--------------+ +-----+ | > ;; | | cpio-modes | | cpio-generic | | ··· | | > ;; | +------------+ +--------------+ +-----+ | > ;; +----------------------------------------------------------+ > > Could you point me to your code? Thanks. At a first glance, what you call "generic code" could be based on the back end. Maybe there's something missing, but it could be a starter. Best regards, Michael. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-02-02 16:30 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2018-02-02 4:14 cpio-mode Douglas Lewan 2018-02-02 13:48 ` cpio-mode Michael Albinus 2018-02-02 15:47 ` cpio-mode Douglas Lewan 2018-02-02 16:30 ` cpio-mode Michael Albinus
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).