09 February 2013, 10:28 | #1 |
Registered User
Join Date: Mar 2008
Location: Berlin/Germany
Posts: 226
|
AmigaDOS: call several commands in a single command line
Hi everyone,
I'm wondering if it is possible to call a whole chain of commands in a single command line (executed one by one). In a Linux shell you would use ';' or '&&' to achieve this. Is there a similar way for AmigaDOS? |
09 February 2013, 10:50 | #2 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
CTRL+J after each command should work.
|
09 February 2013, 10:55 | #3 |
Registered User
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,365
|
You can get a new line without processing the previous command with [CTRL J]
Code:
Try this: echo 1 [CTRL J] echo 2 [CTRL J] echo 3 or use Run with a "+" at the end of the line: Run echo 1 + echo 2 + echo 3 Last edited by PeterK; 09 February 2013 at 14:36. |
09 February 2013, 14:02 | #4 |
Registered User
Join Date: Mar 2008
Location: Berlin/Germany
Posts: 226
|
ARRRGGH... I was about to complain that your suggestions don't work, but, in fact, they do work if executed in a vanilla CLI or Shell window. On the other hand they behave odd in ViNCEd which is my preferred shell (if I connect several commands with Ctrl+J only the last one will be executed), but I think I can work with that. Thank you very much for your help.
|
09 February 2013, 14:05 | #5 |
Registered User
Join Date: Jan 2002
Location: Germany
Posts: 6,985
|
Install Pipe 1.5 from Aminet and follow the docs. Then you can seperate several commands by ||.
|
09 February 2013, 14:33 | #6 |
Registered User
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,365
|
Sorry for the >NIL: in my example....
That was a little bit too ambitious, just pointless for the echo commands. If you use the pipe, as Thomas suggested, then don't forget to define it in the S:Shell-Startup: Set _pchar "|" Set _mchar "||" |
09 February 2013, 16:51 | #7 |
Registered User
Join Date: Mar 2008
Location: Berlin/Germany
Posts: 226
|
@PeterK: I know, echo was just an example and I got your point.
Pipe is a nice little tool. It also enables you to use PIPE: in a MSDOS/Unix like manner. I'll see about it. |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
AmigaDOS echo command speechmark | Retro1234 | support.Other | 3 | 01 May 2012 21:14 |
HDD from command line | brolly | support.WinUAE | 2 | 29 March 2012 22:46 |
is there new command line ? | turrican3 | support.WinUAE | 1 | 15 April 2007 12:21 |
command line? | Drake1009 | support.WinUAE | 7 | 14 August 2004 17:17 |
Command Line. | ruttolibero | support.WinUAE | 1 | 25 July 2003 15:05 |
|
|