The ROOT data analysis framework commonly used in high energy physics uses a binary file format that has internal structure like a real filesystem (i.e. folder & files). The ls() method output from the program look something like this:
KEY: TH1D name1
KEY: TH1D name2
KEY: TH2D name3
....
Where "TH1D" and "TH2D" etc. are just object type. It'd be so nice to browse the file in a dired-like interface in emacs. I certainly don't have the energy/time to write a dired interface for this from scratch (even with the help of the dired.el source). My question is: if possible, how can I just tape into the dired interface by re-implementing some functions to make a dired-like interface for the output like above?
I'm certainly not expecting a full-solution here, but rather pointers to examples, tutorial, and other useful info.
You can start Dired Mode with C-x d , which will then prompt you to enter the directory you wish to view. You can also enter Dired with C-x C-f and then typing the directory you wish to view (as opposed to entering a filename). Dired Mode is a read-only buffer, so many of the commands are single letter keystrokes.
Typing "c" in dired mode will prompt you creating new untitled file. Then press enter will create new untitled file.
In Emacs, type M-x dired. You will be prompted for the directory to open. Type in the directory to display, or press Return to open the default directory.
archive-mode
or tar-mode
might be good starting points.
If it's similar enough to a filesystem, perhaps you could write somekind of loopback driver taht actually allows you to mount the datafile as a filesystem, similar to the way you can mount an ISO image as a filesystem. My very limited understanding is that this isn't a terribly hard thing to do under Linux.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With