[lokisetup] Stupid question

Ryan C. Gordon icculus at clutteredmind.org
Thu May 23 15:27:42 EDT 2002


> Well I don't see why not. All you need is a simple script that either
> calls a program bundled with your installer, or locate installed
> commands that are able to play music or whatever.

Hmm...we could make the stdin of the executed script hook up to the
installer, so as they read from there they can get installation progress
info.

Something like:

#!/usr/bin/perl -w

while (<STDIN>) {
    # the main setup process just keeps writing percentage strings to
    # this pipe, and EOF when it's done.

    print "installation is $_% complete";

    if ($_ <= 10) {
         render_feature_screen_1();
    } else if ($_ <= 50)
         render_feature_screen_2();
    } else if ($_ <= 80) {
         render_coming_soon_screen();
    } else {
         render_thanks_for_purchasing_screen();
    }
}

exit 0;


...obviously, it doesn't have to be perl, it can be anything that can be
executed and read from stdin, but that might be interesting.

--ryan.






More information about the Lokisetup mailing list