LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   script execution (https://www.linuxquestions.org/questions/programming-9/script-execution-220466/)

Johng 08-21-2004 06:19 AM

script execution
 
I am looking for a method to issue a general command in a script to test a DVD compilation in a current directory using xine.

If the current directory is /home/john/video/trial , the command to execute to perform the test would be: xine dvd:/home/john/video/trial/dvd/

If I could save the output of pwd to a string $DVD, I could execute: xine dvd:$DVD/dvd/

Can someone suggest how I can do so, or similar?

david_ross 08-21-2004 08:50 AM

You can use:
DVD=`pwd`

Or just:
xine dvd:`pwd`/dvd/

In which case you may just want to use an alias as opposed to a script:
alias dvdtest="xine dvd:\`pwd\`/dvd/"

Johng 08-21-2004 04:58 PM

Thank you David

That did the trick,

Cheers


All times are GMT -5. The time now is 12:26 AM.