[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gimp-user
Subject:    [Gimp-user] Re: [Gimp-developer] What to do if gimp should run some other commands before and/or aft
From:       Austin Donnelly <austin () gimp ! org>
Date:       2001-03-23 10:17:51
[Download RAW message or body]

On Friday, 23 Mar 2001, Christoph =?ISO-8859-1?Q?Hinterm=FCller?= wrote:

> I do have a question about running or better lounching plugins:
> 
>     how can i get gimp to run some extra commands before and/or
>     after launching a plugin like xsane.
>     eg: a command which tries to activate scanner on scsi bus before
> calling xsane
>         and
>         a command deactivating it again after xsane was closed again
>     But is schould not happen when gimps starts, as it is not 
> necessaryliy that
>     eg the scanner is turend on at that time.
>     And eg the scanner might be turned off again before gimp finishes :(

I would rename xsane to xsane.real and replace it with a shell script
wrapper which does something like:

#!/bin/sh
set -e
/usr/local/lib/xsane/xsane-startup
xsane.real "$@"
/usr/local/lib/xsane/xsane-shutdown

No gimp hackery required.

The two scripts xsane-startup and xsane-shutdown can contain whatever
commands are needed to initialise and turn off your scanner etc.

Austin
_______________________________________________
Gimp-user mailing list
Gimp-user@lists.xcf.berkeley.edu
http://lists.xcf.berkeley.edu/mailman/listinfo/gimp-user

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic