Need some help with a script

Discussion in 'Programming/Scripts' started by ocvdave, Jun 21, 2007.

  1. ocvdave

    ocvdave New Member

    I need some help with a script I'm writing. So far it works if it's invoked inside a terminal window, but I really need to make it work from an icon and run in it's own terminal window. I've played with several gnome-terminal options and haven't been able to get more than just the first command to work. The only way I've been able to do it so far is to create a second script that calls the actual script to open in a new terminal (gnome-terminal --command="myscript"). This all must be done inside the script as it is going to be deployed over removable media and changes cannot be made to the os to accomodate this.

    Here is a sample of the script:


    echo "blah blah" (I like to post messages to the users)

    su -c 'command string';command string

    echo "verify that it worked"

    fconf info|grep log

    echo "hit me to exit"


    That's not the whole thing but if I can figure it out for one part......

    I know this may seem simple to most but if you could help me out I would appreciate it.

  2. falko

    falko Super Moderator ISPConfig Developer

    Have you tried to use full paths (e.g. /usr/bin/su instead of su) in the script or set a PATH variable?
  3. ocvdave

    ocvdave New Member

    As a matter of fact, I had not... But I just did... nothing... It's not even pausing for the read command I inserted to see if I could get it to freeze

Share This Page