Re: desktop.links entries - was Re: Advocacy report [part 2]




> So now I want to create an entry in my
> /usr/lib/desktop-links/desktop.links file so that users can just choose
> recreate default icons to get a new automounting floppy icon. I tried this
> 
> [floppy]
> title=floppy
> type=file
> file=/misc/floppy
> icon=i-floppy.png
> 
> however this doesn't work. The only type gmc seems to like is url. I want
> a link to /misc/floppy but type=file or link doesn't work. Is it possible?

You can provide arbitrary programs that setup the desktop directory, I 
think it goes something like this (just run this script):

#!/bin/sh

cat > setup-user-links << EOF
#!/bin/sh
#
# This script is invoked by gmc like this:
# setup-user-links --desktop-dirpath
# Due to a bug

case $1
in
    --desktop-dir*)
	dir=`echo $1 | ed 's/--desktop-dir//' | sed 's/^=//'`
	(cd $1 && ln -s /mnt/misc/floppy .)
	;;
esac)
EOF
cp setup-user-links `gmc --desktop-linksdir`

Hope this helps,
Miguel
-- 
miguel@gnu.org



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]