[gobolinux-users] Listener 1.1

Jonatan Liljedahl lijon at kymatica.com
Tue Aug 16 11:18:13 GMT 2005

On Tue, 16 Aug 2005 12:00:06 +0200
kenneth marken <k-marken at online.no> wrote:

> Lucas Correia Villa Real wrote:
> > On Monday 15 August 2005 19:49, kenneth marken wrote:
> > 
> >>cant say i have heard about anything similar for linux. most likely
> >it>would require some kind of buildt in function in your file browser
> >of>choice, this in combo with the commandline burner tools or
> >something.>
> >>hmm, that reminds me. are mkisofs able to handle symlinks? if so
> >then>you can create a folder, symlink in everything you want (or set
> >up a>similar solution to listener so that any file dropped on the
> >folder are>symlinked inside the folder) and then run a mkisofs aimed
> >at the folder.
> > 
> > 
> > Yes, that's it. One would configure Listener to launch k3b or
> > cdrecord after a special file is placed inside the "virtual folder".
> > However, the following seems to be more user-friendly: one rule
> > would create symlinks for every file/directory dropped there (eg:
> > /Depot/CDRecord/Environment/), while another would listen for
> > another directory (eg: /Depot/CDRecord/Burn/). So, when the user
> > drops the folder which contains the symlinks into this second one,
> > mkisofs+cdrecord should be launched.
> > 
> just checked a bit and mkisofs have a -f option that looks like its 
> supposed to follow symlinks when creating a iso. but i have no 
> experience using the raw mkisofs and cdrecord tools so i dont know
> what the right settings to create a iso based on a folder full of
> symlinks are._______________________________________________

The only problem with that approach is that you can't have any symlinks
in the actual created filesystem in that case... 

And regarding Listener (inotify), as far as I can see inotify can send
an event when a file is created or moved there. But we don't want to
create or move any data there! The original file should be kept where it
is, and we don't want to copy the data when it's theoretically not
needed. Here's what I've thought with using FUSE:

~] fusemkiso MyISO
#The dir is created if non-existent, if the dir existed and wasn't empty
#- exit with an error...
~] cd MyISO
~/MyISO] ls
Root/  MyISO.iso
~/MyISO] cd Root
~/MyISO/Root] ln -s ~/Foo .
~/MyISO/Root] ln -s ~/Bar.txt .
#internal references is stored in the fs, it's not actual symlinks...
~/MyISO/Root] ls
Foo/  Bar.txt
#an ls -l would show the real filesizes
~/MyISO/Root] cd ..
~/MyISO] cp MyISO.iso ~/
#as the MyISO.iso file is read, a real iso image is now created
#you could also just burn this iso image from here without copying it
~/MyISO] cd ..
~] fusermount -u MyISO
#unmounted... could fusemkiso detect the unmount and write the iso image
#on stdout (if cmdline option was specified), so that it could be piped
#into a DnD savebox GUI... And also delete the mountpoint if it wasn't
#existing at startup...

/Jonatan    -=( http://kymatica.com )=-

More information about the gobolinux-users mailing list