+ Reply to Thread
Results 1 to 2 of 2

Thread: unix script - run in same shell

  1. #1
    kbjradmin's Avatar
    kbjradmin is offline x10 Elder kbjradmin is an unknown quantity at this point
    Join Date
    Feb 2008
    Location
    Washington State, USA
    Posts
    512

    unix script - run in same shell

    i know that a command can be forced to run in the current shell, as opposed to a new one, by placing a dot before it, ie.
    Code:
    $   . somescript args
    is there any way to do this in the shebang line, so that the script always runs in the current shell, regardless of whether there is a dot?



    edit:
    another question, is there some way to declare a variable where the name is decided by the value of another variable, ie.
    Code:
    declare -a $varOne=( 1 2 3 4 5 )
    (except that doesn't work)
    Last edited by kbjradmin; 02-14-2009 at 03:29 PM.

  2. #2
    kbjradmin's Avatar
    kbjradmin is offline x10 Elder kbjradmin is an unknown quantity at this point
    Join Date
    Feb 2008
    Location
    Washington State, USA
    Posts
    512

    Re: unix script - run in same shell

    i still need help here people... :dunno:

    i got the second one, but the first one i still need help on.
    Last edited by kbjradmin; 02-16-2009 at 05:33 PM.

+ Reply to Thread

Similar Threads

  1. Unix Shell Password Check
    By kbjradmin in forum Programming Help
    Replies: 9
    Last Post: 01-24-2009, 11:11 AM
  2. Unix Shell Script
    By kbjradmin in forum Programming Help
    Replies: 2
    Last Post: 01-23-2009, 09:59 AM
  3. Access to 300+ PHP scripts (2500 credits)
    By jonathanyaniv in forum The Marketplace
    Replies: 11
    Last Post: 06-03-2008, 10:58 PM
  4. mass video conversion shell script
    By hopper in forum Computers & Technology
    Replies: 0
    Last Post: 04-28-2008, 05:33 PM
  5. Replies: 8
    Last Post: 12-03-2007, 04:12 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers