shell Script working

i wrote a shell program in Home Directory.
and i changed to other directory.
i want to try to execute shell script in Other Dir.
it is not executed.
how can i make this script to execute in other directory also??

Thanks,
Arun

Set the path in environment variable and try to execute.

 export env_variable=PATH

Set PATH variable including the directory where your shell scripts locate in.
Or execute it using absolute path.

please give me the sample code.

can you provide your script here.. so that we can check what you exactly doing and what is wrong

# .bashrc file
alias show='sh 1.sh'
----this is in home dir--
---again i changed to arun dir--

>cd arun
#and iam trying to execute ..alias name (show)
i.e
>show
#it is not executed

please tell me how can i set PATH variable.

when ever you are setting the alias, you need to provide the absolute path

 
alias show='sh /absolute/path/of/1.sh'

/absolute/path/of/ ---

what is this represents??

---------- Post updated at 02:19 AM ---------- Previous update was at 02:16 AM ----------

it is not executed for me while im executing.

where is your 1.sh ?

/home/arun/1.sh ??????

it is not in arun dir..
it is in home dir.

---------- Post updated at 02:32 AM ---------- Previous update was at 02:29 AM ----------

i.e 1.sh present in Home dir.

google for "absolute path in linux" and "relative path in linux"

And in your alias, apply the absolute path for 1.sh

absolute path is nothing but, the path of the from the root directory ( / )

You can type

/home/1.sh'