Re: Probably very stupid script/bash question

2008-03-05 Thread Brian
Mark Clarkson wrote: On Tue, 04 Mar 2008 18:46:05 +0100 Brian [EMAIL PROTECTED] wrote: I could not get this to work, the shell complains: ./dirvish-mail.sh: 98: Syntax error: redirection unexpected Interesting to note that this does not work under busybox. I think this is rather an

Re: Probably very stupid script/bash question

2008-03-05 Thread Bob McGowan
Brian wrote: Mark Clarkson wrote: On Tue, 04 Mar 2008 18:46:05 +0100 Brian [EMAIL PROTECTED] wrote: I could not get this to work, the shell complains: ./dirvish-mail.sh: 98: Syntax error: redirection unexpected Interesting to note that this does not work under busybox. I think this is

Re: Probably very stupid script/bash question

2008-03-05 Thread Mark Clarkson
On Wed, 05 Mar 2008 12:16:02 -0800 Bob McGowan [EMAIL PROTECTED] wrote: Brian wrote: So can you explain exactly what the first ( echo $teststring ) does exactly please? In any case, I'd be interested in knowing where you found this construct. The bash man page seems to be one of

Re: Probably very stupid script/bash question

2008-03-05 Thread Bob McGowan
Mark Clarkson wrote: On Wed, 05 Mar 2008 12:16:02 -0800 Bob McGowan [EMAIL PROTECTED] wrote: Brian wrote: So can you explain exactly what the first ( echo $teststring ) does exactly please? In any case, I'd be interested in knowing where you found this construct. The bash man page

Re: Probably very stupid script/bash question

2008-03-05 Thread Mark Clarkson
On Wed, 05 Mar 2008 13:10:37 -0800 Bob McGowan [EMAIL PROTECTED] wrote: Mark Clarkson wrote: On Wed, 05 Mar 2008 12:16:02 -0800 Bob McGowan [EMAIL PROTECTED] wrote: Brian wrote: So can you explain exactly what the first ( echo $teststring ) does exactly please? In any case,

Re: Probably very stupid script/bash question

2008-03-05 Thread Bob McGowan
Mark Clarkson wrote: On Wed, 05 Mar 2008 13:10:37 -0800 Bob McGowan [EMAIL PROTECTED] wrote: Mark Clarkson wrote: On Wed, 05 Mar 2008 12:16:02 -0800 Bob McGowan [EMAIL PROTECTED] wrote: Brian wrote: So can you explain exactly what the first ( echo $teststring ) does exactly please?

Re: Probably very stupid script/bash question

2008-03-05 Thread William Pursell
Mark Clarkson wrote: On Wed, 05 Mar 2008 13:10:37 -0800 Bob McGowan [EMAIL PROTECTED] wrote: If I do the process substitution using a stand alone programs, it works as described: $ wc (echo this is a test) 1 4 15 /dev/fd/63 I couldn't find the correct place to

Re: Probably very stupid script/bash question

2008-03-05 Thread Rich Healey
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 William Pursell wrote: I couldn't find the correct place to interject this question in the thread, so I fairly randomly selected this location... As far as I can tell, the following 4 commands should all behave the same, but the last one hangs.

Re: Probably very stupid script/bash question

2008-03-05 Thread Mike Bird
On Wed March 5 2008 15:36:50 William Pursell wrote: As far as I can tell, the following 4 commands should all behave the same, but the last one hangs. Can anyone see why? $ cat (echo foo) foo $ bash -c 'cat (echo foo)' foo $ echo foo | bash -c 'cat' foo $ bash -c 'cat' (echo foo) The

Re: Probably very stupid script/bash question

2008-03-04 Thread Brian
Georg Neis wrote: Brian wrote: The following does not (the value is empty): echo $teststring | { read A B C D E F; } echo Data received = $E Bytes --- $E is empty I assume it has something to do with the read command being executed in a subshell. Yes. So how can I extract the parts I

Re: Probably very stupid script/bash question

2008-03-04 Thread Brian
Mark Clarkson wrote: On Mon, 2008-03-03 at 19:48 +0100, Brian wrote: echo $teststring | { read A B C D E F; } echo Data received = $E Bytes --- $E is empty { read A B C D E F; } ( echo $teststring ) echo Data received = $E Bytes --- $E is empty Robomod, I could not get this to work,

Re: Probably very stupid script/bash question

2008-03-04 Thread Mark Clarkson
On Tue, 04 Mar 2008 18:46:05 +0100 Brian [EMAIL PROTECTED] wrote: I could not get this to work, the shell complains: ./dirvish-mail.sh: 98: Syntax error: redirection unexpected Interesting to note that this does not work under busybox. I think this is rather an esoteric but often useful

Re: Basic bash question.

2008-03-04 Thread Andrew Sackville-West
On Mon, Mar 03, 2008 at 08:08:47PM -0800, joseph lockhart wrote: Luis Maceira [EMAIL PROTECTED] wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is

Re: Basic bash question.

2008-03-04 Thread Chris Henry
On Wed, Mar 5, 2008 at 6:16 AM, Andrew Sackville-West [EMAIL PROTECTED] wrote: On Mon, Mar 03, 2008 at 08:08:47PM -0800, joseph lockhart wrote: Luis Maceira [EMAIL PROTECTED] wrote: How can I see all the messages generated by a bash command (configure make make install, for example)

Probably very stupid script/bash question

2008-03-03 Thread Brian
Hi, I tried using bash to split a string. This works OK: echo $teststring | { read A B C D E F; echo Data received = $E Bytes; } The following does not (the value is empty): echo $teststring | { read A B C D E F; } echo Data received = $E Bytes --- $E is empty I assume it has something to

Re: Probably very stupid script/bash question

2008-03-03 Thread Alex Samad
On Mon, Mar 03, 2008 at 07:48:49PM +0100, Brian wrote: Hi, I tried using bash to split a string. This works OK: echo $teststring | { read A B C D E F; echo Data received = $E Bytes; } The following does not (the value is empty): echo $teststring | { read A B C D E F; } echo Data

Re: Probably very stupid script/bash question

2008-03-03 Thread Mark Clarkson
On Mon, 2008-03-03 at 19:48 +0100, Brian wrote: echo $teststring | { read A B C D E F; } echo Data received = $E Bytes --- $E is empty { read A B C D E F; } ( echo $teststring ) echo Data received = $E Bytes --- $E is empty -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of

Re: Probably very stupid script/bash question

2008-03-03 Thread Georg Neis
Brian wrote: The following does not (the value is empty): echo $teststring | { read A B C D E F; } echo Data received = $E Bytes --- $E is empty I assume it has something to do with the read command being executed in a subshell. Yes. So how can I extract the parts I want into

Basic bash question.

2008-03-03 Thread Luis Maceira
How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is written to a text file for later analysis. It is a redirection but I don´t know how to make both things happen at

Re: Basic bash question.

2008-03-03 Thread Chris Henry
Hi, You can use tee. e.g. ./configure | tee filename Chris On Tue, Mar 4, 2008 at 11:33 AM, Luis Maceira [EMAIL PROTECTED] wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time

Re: Basic bash question.

2008-03-03 Thread Kumar Appaiah
On Mon, Mar 03, 2008 at 07:33:20PM -0800, Luis Maceira wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is written to a text file for later analysis. It is

Re: Basic bash question.

2008-03-03 Thread Ken Irving
On Mon, Mar 03, 2008 at 07:33:20PM -0800, Luis Maceira wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is written to a text file for later analysis. It is

Re: Basic bash question.

2008-03-03 Thread Kevin Mark
On Mon, Mar 03, 2008 at 07:33:20PM -0800, Luis Maceira wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is written to a text file for later analysis. It is

Re: Basic bash question.

2008-03-03 Thread joseph lockhart
Luis Maceira [EMAIL PROTECTED] wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is written to a text file for later analysis. It is a redirection but I don´t

Re: Basic bash question.

2008-03-03 Thread hhding
Any method to redirect any fd to the pipe? Not only stdout,stderr. Chris Henry wrote: Hi, You can use tee. e.g. ./configure | tee filename Chris On Tue, Mar 4, 2008 at 11:33 AM, Luis Maceira [EMAIL PROTECTED] wrote: How can I see all the messages generated by a bash command (configure

Re: Basic bash question.

2008-03-03 Thread Rich Healey
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hhding wrote: Any method to redirect any fd to the pipe? Not only stdout,stderr. Chris Henry wrote: Hi, You can use tee. e.g. ./configure | tee filename Chris On Tue, Mar 4, 2008 at 11:33 AM, Luis Maceira [EMAIL PROTECTED] wrote: How

Re: Basic bash question.

2008-03-03 Thread Kumar Appaiah
On Tue, Mar 04, 2008 at 12:10:25PM +0800, hhding wrote: Any method to redirect any fd to the pipe? Not only stdout,stderr. If you mean both stdout and stderr ./configure 21 | tee log.txt would work. But I don't know if that is what you meant. HTH. Kumar -- Kumar Appaiah, 458, Jamuna

Re: Basic bash question.

2008-03-03 Thread hhding
It's my fault. I mistake something like this exec 61 1- echo To a closed fd Kumar Appaiah wrote: On Tue, Mar 04, 2008 at 12:10:25PM +0800, hhding wrote: Any method to redirect any fd to the pipe? Not only stdout,stderr. If you mean both stdout and stderr ./configure 21 | tee log.txt

Re: Basic bash question.

2008-03-03 Thread Rich Healey
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 joseph lockhart wrote: Luis Maceira [EMAIL PROTECTED] wrote: How can I see all the messages generated by a bash command (configure make make install, for example) to standard output(computer screen), and at the same time make sure that all is

yet another bash question

2006-11-07 Thread Richard Lyons
For things like saving photos to hard disk, I tend to use a few bash scripts to rename the files, keeping the numerical part and coding something else in place of the cimg. For example, I might change all the files cimg1234.jpg to cimg1299.jpg to be called foobar234.jpg to foobar299.jpg. I tend

Re: yet another bash question

2006-11-07 Thread Roberto C. Sanchez
On Tue, Nov 07, 2006 at 03:16:38PM +, Richard Lyons wrote: For things like saving photos to hard disk, I tend to use a few bash scripts to rename the files, keeping the numerical part and coding something else in place of the cimg. For example, I might change all the files cimg1234.jpg to

Re: yet another bash question

2006-11-07 Thread Andrew Sackville-West
On Tue, Nov 07, 2006 at 03:16:38PM +, Richard Lyons wrote: For things like saving photos to hard disk, I tend to use a few bash scripts to rename the files, keeping the numerical part and coding something else in place of the cimg. For example, I might change all the files cimg1234.jpg to

Re: yet another bash question

2006-11-07 Thread Chris
On Tuesday 07 November 2006 16:16, Richard Lyons wrote: For things like saving photos to hard disk, I tend to use a few bash scripts to rename the files, keeping the numerical part and coding something else in place of the cimg. For example, I might change all the files cimg1234.jpg to

Re: Bash question

2003-07-02 Thread Jamin W. Collins
On Tue, Jul 01, 2003 at 06:52:26PM +0100, Colin Watson wrote: On Tue, Jul 01, 2003 at 07:43:28AM -0600, Jamin W. Collins wrote: This has been asked and answered a few times in the past. There are several ways to do it. Here is one: #!/bin/sh IFS=$'\n' for FILE in `ls

Re: Bash question

2003-07-02 Thread Jon Haugsand
* Shawn Lamson for file in `ls` do mpg123 $file done Really? $ touch aa aa $ touch bb $ for file in `ls`; do echo $file; done aa aa bb -- Jon Haugsand, [EMAIL PROTECTED] http://www.norges-bank.no -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble?

Re: Bash question

2003-07-02 Thread matt zagrabelny
beating this to death: #!/bin/bash IFS= for file in $(ls -1); do echo $file done cheers, -matt zagrabelny -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]

Bash question

2003-07-01 Thread Stephan Sauerburger
This is a general shell-scripting question: In a for loop which runs through all files, as in: for file in `ls` do #stuff done How do I have it make sure it iterates file-by-file? The following example, to play all mp3s in the current directory: for file in `ls` do mpg123 $file done ...will do

Re: Bash question

2003-07-01 Thread David Z Maze
Stephan Sauerburger [EMAIL PROTECTED] writes: In a for loop which runs through all files, as in: for file in `ls` do #stuff done ITYM 'for file in *'... ...will do just a fine job, so long as none of the file names have any spaces in them. because it gets around this. In general,

Re: Bash question

2003-07-01 Thread Jamin W. Collins
On Tue, Jul 01, 2003 at 02:46:58AM -0500, Stephan Sauerburger wrote: So how can one have the for loop separate the elements of the list only by newlines (\n), filling the contents of file with the whole line, and not separate by spaces, tabs, or other white space? This has been asked and

Re: Bash question

2003-07-01 Thread Shawn Lamson
On Tue, July 01 at 2:46 AM EDT Stephan Sauerburger [EMAIL PROTECTED] wrote: So how can one have the for loop separate the elements of the list only by newlines (\n), filling the contents of file with the whole line, and not separate by spaces, tabs, or other white space? You'll probably get a

Re: Bash question

2003-07-01 Thread Jon Haugsand
* Stephan Sauerburger This is a general shell-scripting question: In a for loop which runs through all files, as in: for file in `ls` do #stuff done How do I have it make sure it iterates file-by-file? The following example, to play all mp3s in the current directory: for file in

Re: Bash question

2003-07-01 Thread thomas . gies
Hi. Try find. It has the -exec parameter. That is what you want. -- Die Welt ist kunterbunt, mein Arsch wiegt 180 Pfund. - Hans Peter Gies, 1989 pgp0.pgp Description: PGP signature

Re: Bash question

2003-07-01 Thread Hugh Saunders
On Tue, Jul 01, 2003 at 10:28:32AM -0400, David Z Maze wrote: ITYM 'for file in *'... ISTR earlier versions... flip man! i needed two references to `dict` to read your email. Guess i should learn some acronyms! -- hugh pgp0.pgp Description: PGP signature

Re: Bash question

2003-07-01 Thread Johannes Zarl
for file in *.ogg; do ogg123 $file done (Since the double-quotes allow variable expansion, but force the result to be a single world for shell purposes.) To deal with all (im)possible filenames, you could even do: for file in *.ogg do ogg123 -- $file done Just in case you have

Re: Bash question

2003-07-01 Thread Lukas Ruf
Jon Haugsand [EMAIL PROTECTED] [2003-07-01 19:43]: in your directory. A very failsafe variant is to use find: find . -type f -print0 | xargs -0 mpg123 I usually make use of find's parameter -maxdepth level if you would like to restrict the search to a certain depth of the directory tree

Re: Bash question

2003-07-01 Thread Colin Watson
On Tue, Jul 01, 2003 at 07:43:28AM -0600, Jamin W. Collins wrote: On Tue, Jul 01, 2003 at 02:46:58AM -0500, Stephan Sauerburger wrote: So how can one have the for loop separate the elements of the list only by newlines (\n), filling the contents of file with the whole line, and not separate

Re: Bash question

2003-07-01 Thread Alfredo Valles
On Tuesday 01 July 2003 3:18 pm, Colin Watson wrote: There's one mistake in the above even before looking at the contents of #stuff, namely that you shouldn't be using ls here. Have a look at this document written by a friend of mine: http://www.greenend.org.uk/rjk/2001/04/shell.html

Re: Bash question

2003-07-01 Thread Colin Watson
On Tue, Jul 01, 2003 at 02:04:35PM +0200, Alfredo Valles wrote: On Tuesday 01 July 2003 3:18 pm, Colin Watson wrote: There's one mistake in the above even before looking at the contents of #stuff, namely that you shouldn't be using ls here. Have a look at this document written by a friend

Re: Bash question

2003-07-01 Thread Alfredo Valles
On Tuesday 01 July 2003 9:46 am, Stephan Sauerburger wrote: How do I have it make sure it iterates file-by-file? The following example, to play all mp3s in the current directory: for file in `ls` do mpg123 $file done ...will do just a fine job, so long as none of the file names have any

Re: Bash question

2003-07-01 Thread Richard Heycock
ls | while read file do cat $bob done for loops treat spaces and newlines the same (which is what you are seeing), the read command reads till the end of the line including spaces. Note that when you use the environment variable you must quote it (be sure to use as opposed to '). If you

Re: Bash question

2003-07-01 Thread Kevin McKinley
On Tue, 1 Jul 2003 15:41:56 +0100 Hugh Saunders [EMAIL PROTECTED] wrote: On Tue, Jul 01, 2003 at 10:28:32AM -0400, David Z Maze wrote: ITYM 'for file in *'... ISTR earlier versions... flip man! i needed two references to `dict` to read your email. Guess i should learn some acronyms!

Re: bash question: reporting a variable named within a variable

2003-04-04 Thread Corey Hickey
Indeed, eval did the trick, exactly what I wanted to do. Thanks to all who responded, you were most helpful. -Corey -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]

Re: bash question: reporting a variable named within a variable

2003-04-04 Thread Rob Sims
On Thursday 03 April 2003 08:01 pm, Bob Proulx wrote: Craig Dickson wrote: echo $var=$(eval echo \$$var) That works. Personally I prefer to eval the entire line. This way you only use one layer of processing rather than the two in the above. for var in FOO BLAH ; do eval

bash question: reporting a variable named within a variable

2003-04-03 Thread Corey Hickey
Hello, This isn't exactly a debian-specific question, but I'm not sure where else to turn. I'm writing a bash script wherein I have a list of variables of which I want to return the values. A script representative of what I am trying to do would be like this: #!/bin/bash FOO=bar BLAH=blarg for

Re: bash question: reporting a variable named within a variable

2003-04-03 Thread Craig Dickson
Corey Hickey wrote: I'm writing a bash script wherein I have a list of variables of which I want to return the values. A script representative of what I am trying to do would be like this: #!/bin/bash FOO=bar BLAH=blarg for var in FOO BLAH ; do echo $var = $$var #this part

Re: bash question: reporting a variable named within a variable

2003-04-03 Thread Colin Watson
On Thu, Apr 03, 2003 at 01:58:35PM -0800, Corey Hickey wrote: This isn't exactly a debian-specific question, but I'm not sure where else to turn. I'm writing a bash script wherein I have a list of variables of which I want to return the values. A script representative of what I am trying to

Re: bash question: reporting a variable named within a variable

2003-04-03 Thread Bob Proulx
Craig Dickson wrote: echo $var=$(eval echo \$$var) That works. Personally I prefer to eval the entire line. This way you only use one layer of processing rather than the two in the above. for var in FOO BLAH ; do eval echo $var = \$$var; done For those following this scripting

Re: bash question: reporting a variable named within a variable

2003-04-03 Thread Colin Watson
On Fri, Apr 04, 2003 at 12:34:33AM +0100, Colin Watson wrote: On Thu, Apr 03, 2003 at 01:58:35PM -0800, Corey Hickey wrote: #!/bin/bash FOO=bar BLAH=blarg for var in FOO BLAH ; do echo $var = $$var #this part is messed up done Try this, which I believe to be the best way:

Quick Bash question

2003-01-03 Thread Bill Moseley
In a shell script does: MODPROBE=: do anything special besides set $MODPROBE to :? Why I ask is the hotplug usb.agent script does: MODPROBE=: for MAP in $MAP_USERMAP $HOTPLUG_DIR/usb/*.usermap do if [ -r $MAP ]; then load_drivers usb $MAP $LABEL

Re: Quick Bash question

2003-01-03 Thread Colin Watson
On Fri, Jan 03, 2003 at 12:22:14AM -0800, Bill Moseley wrote: In a shell script does: MODPROBE=: do anything special besides set $MODPROBE to :? No. MODPROBE=: [...] debug_mesg Looking for module $MODULE with modprobe=$MODPROBE if $MODPROBE -n $MODULE

Re: Quick Bash question

2003-01-03 Thread Bill Moseley
On Fri, 3 Jan 2003, Colin Watson wrote: On Fri, Jan 03, 2003 at 12:22:14AM -0800, Bill Moseley wrote: In a shell script does: MODPROBE=: do anything special besides set $MODPROBE to :? No. MODPROBE=: [...] debug_mesg Looking for module $MODULE with

Re: Quick Bash question

2003-01-03 Thread Bill Moseley
On Fri, 3 Jan 2003, Bill Moseley wrote: In other words, from what I can see it seems as if the program foo is not run, although it it claims ran foo. if : -n foo /dev/null 21 ! : foo /dev/null 21 ; then echo failed to load else echo ran foo fi Never mind. Now

Re: BASH question

2002-02-20 Thread Karl E. Jorgensen
On Tue, Feb 19, 2002 at 05:42:35PM +0100, Viktor Rosenfeld wrote: Hi, I have the following bash question. I've written a script that makes sure that I'm online (ISDN dial-on-demand) and then gets mail with fetchmail. He're the code that makes sure I'm connected and prints dots while doing

Re: BASH question

2002-02-20 Thread Viktor Rosenfeld
Karl E. Jorgensen wrote: With kill -9, there is no way the shell can catch it. It's a bit of a shotgun approach to getting rid of the process (man 7 signal). However, if you were to settle for the normal kill (= SIGTERM), then you should be OK: #!/bin/sh echo -n Doing

BASH question

2002-02-19 Thread Viktor Rosenfeld
Hi, I have the following bash question. I've written a script that makes sure that I'm online (ISDN dial-on-demand) and then gets mail with fetchmail. He're the code that makes sure I'm connected and prints dots while doing so: # Make sure we're online echo -n Connecting

Re: bash question.

2002-02-07 Thread Petrov M.I.
Hi All. How do you _read_ from the printer, which is an output device? Are you trying to get status info back from the printer? Yes. I want to get status info. When I do `echo -e ...' then `cat /dev/lp0' from command line, this work correctly. When I do from script this do not work. You'd

Re: bash question.

2002-02-07 Thread Ron Johnson
On Thu, 7 Feb 2002 15:49:25 +0200 (EET) Petrov M.I. [EMAIL PROTECTED] wrote: Hi All. How do you _read_ from the printer, which is an output device? Are you trying to get status info back from the printer? Yes. I want to get status info. When I do `echo -e ...' then `cat /dev/lp0' from

bash question.

2002-02-06 Thread Petrov M.I.
Hi All. I write small script: #!/bin/bash echo -e ...PJL commands... | cat /dev/lp0 cat /dev/lp0 When I try it run I get nothing. When I run this script two time (one after the other) I get informations. I need write to read from /dev/lp0 in one the same script. How do this do? Any help

Re: bash question.

2002-02-06 Thread Ron Johnson
On Wed, 6 Feb 2002 20:30:47 +0200 (EET) Petrov M.I. [EMAIL PROTECTED] wrote: Hi All. I write small script: #!/bin/bash echo -e ...PJL commands... | cat /dev/lp0 Try adding a newline: echo -e ...PJL commands...\n | cat /dev/lp0 cat /dev/lp0 ??? When I try it run I get nothing.

bash question: identify line number of function call

2001-09-14 Thread Martin F Krafft
in bash, is it possible to identify the line number of a script, from where a function has been called? for instance, using the hypothetical print_line_number function, which i am looking for: 1 #!/bin/sh 2 3 function myfn() 4 { 5echo -n this function has been called from line

Re: bash question: identify line number of function call

2001-09-14 Thread Andras BALI
On Fri, Sep 14, 2001 at 05:28:35PM +0200, Martin F Krafft wrote: in bash, is it possible to identify the line number of a script, from where a function has been called? You have $LINENO, but it restarts counting from 1 in functions. But if you invoke the function with $LINENO as argument, the

BASH question

2001-05-12 Thread Sunny Dubey
Hey, Anyone know where I might find info about using BASH to create an installer for a application? something that would just ask the person various questions, and use that info to create config files and what not? thanks Sunny Dubey

Re: BASH question

2001-05-12 Thread Karsten M. Self
on Fri, May 11, 2001 at 03:06:07AM -0400, Sunny Dubey ([EMAIL PROTECTED]) wrote: Hey, Anyone know where I might find info about using BASH to create an installer for a application? something that would just ask the person various questions, and use that info to create config files and what

Re: BASH question

2001-05-12 Thread Henrik Enberg
Karsten M. Self kmself@ix.netcom.com: You could also look at some standard installer scripts...trying to think of one off the top of my head. None are floating up that aren't attached to some monster applications -- DB/2's installer comes to mind, but that's a pretty hefty download.. Mayby

Re: bash-question

2000-12-26 Thread Stephan Kulka
On Mon, Dec 25, 2000 at 10:21:52AM +0100, Stephan Kulka wrote: That's quite a newbie question, but I don't know what to do. Yesterday I made a new directory for programming, I added this directory with export to my PATH. Yesterday everything went fine, but today I always get the error

Re: bash-question

2000-12-26 Thread Carel Fellinger
On Tue, Dec 26, 2000 at 11:55:13AM +0100, Stephan Kulka wrote: On Mon, Dec 25, 2000 at 10:21:52AM +0100, Stephan Kulka wrote: That's quite a newbie question, but I don't know what to do. Yesterday I made a new directory for programming, I added this directory with export to my

bash-question

2000-12-25 Thread Stephan Kulka
That's quite a newbie question, but I don't know what to do. Yesterday I made a new directory for programming, I added this directory with export to my PATH. Yesterday everything went fine, but today I always get the error command not found. I checked my PATH, it i so.k. and the compiled programs

Re: bash-question

2000-12-25 Thread W. Paul Mills
[EMAIL PROTECTED] (Stephan Kulka) writes: I do not think your PATH is really set. How did you check your path? Did you echo $PATH to verify? That's quite a newbie question, but I don't know what to do. Yesterday I made a new directory for programming, I added this directory with export to

Re: bash-question

2000-12-25 Thread Carel Fellinger
On Mon, Dec 25, 2000 at 10:21:52AM +0100, Stephan Kulka wrote: That's quite a newbie question, but I don't know what to do. Yesterday I made a new directory for programming, I added this directory with export to my PATH. Yesterday everything went fine, but today I always get the error command

Re: Bash question

2000-02-09 Thread Paolo Pedaletti
Ciao Andreas Sliwka, where or whom should I ask not-so-easy bash questions? news:comp.unix.shell Ciao -- Paolo Pedaletti, Como, ITALYa [EMAIL PROTECTED]

Bash question

2000-02-08 Thread Andreas Sliwka
Hi, where or whom should I ask not-so-easy bash questions? The one special question or problem is: I want to start a program in a shell script, get the filedescriptor for its standard input and let other programs, which I want to start after the first program, writer there standard output

bash question

1999-02-22 Thread Eugene Sevinian
Hi ppl, As far as I did not find the answer in bash manual, I hope that someone can help me here. Let say I have two bash scripts and I need the parameter which is set in scr2 to be visable in scr1. scr1: #!/bin/sh export LANG=lang1 echo LANG is $LANG in $0 scr2

Re: bash question

1999-02-22 Thread E.L. Meijer \(Eric\)
Hi ppl, As far as I did not find the answer in bash manual, I hope that someone can help me here. Let say I have two bash scripts and I need the parameter which is set in scr2 to be visable in scr1. scr1: #!/bin/sh export LANG=lang1 echo LANG is $LANG in $0

Re: bash question

1999-02-22 Thread Eugene Sevinian
Thanks Eric, I tried sourcing scr2 and it works faster then CALLING scr2. Eugene. On Mon, 22 Feb 1999, E.L. Meijer (Eric) wrote: Hi ppl, As far as I did not find the answer in bash manual, I hope that someone can help me here. Let say I have two bash scripts and I need the parameter

Re: bash question

1999-02-22 Thread E.L. Meijer \(Eric\)
Thanks Eric, I tried sourcing scr2 and it works faster then CALLING scr2. This is to be expected: if you call a script, separate shell is started that runs it. This takes some time. If you source a script, the only overhead is opening and reading an extra file. Eric -- E.L. Meijer

Bash question/problem.

1998-12-18 Thread Jim Lynch
I'v been fighting a bash problem since I first installed bo. I figured it was a bug in bash, but I've now upgraded (partially) to hamm and I've still got it. I'm running ii bash2.01.1-4 The GNU Bourne Again SHell I'm trying to get my command recall to work in vi mode for

Re: Bash question/problem.

1998-12-18 Thread Mitch Blevins
Jim Lynch wrote: I'v been fighting a bash problem since I first installed bo. I figured it was a bug in bash, but I've now upgraded (partially) to hamm and I've still got it. I'm running ii bash2.01.1-4 The GNU Bourne Again SHell I'm trying to get my command recall

Re: BASH question

1998-02-16 Thread Daniel Mashao
On Fri, 13 Feb 1998, Fulgham, Brent/SCO wrote: Can anyone tell me why I can't generate working Bash scripts? For example, I want to create a short script called print so that I can do some formatted printing: #!/bin/sh # Print -- formatted printer tool to get a 5-space margin and a

RE: BASH question

1998-02-16 Thread Fulgham, Brent/SCO
For those who are interested, my BASH problems were due to the presence of some control characters in the script file. I was using the ae editor, which in its latest incarnation was inserting a ^M at the end of each line to signify a carriage return. Once I switched to vi I could see the

Re: BASH question

1998-02-14 Thread Scott McDermott
On Fri, Feb 13, 1998 at 09:50:28AM -0700, Fulgham, Brent/SCO wrote: 1) /bin/bash : No such file name 2) /bin/bash : Invalid file or directorypr --where part of the error message includes the last few characters of each line in the shell script. /bin/sh is not linked to /bin/bash correctly.

BASH question

1998-02-13 Thread Fulgham, Brent/SCO
Can anyone tell me why I can't generate working Bash scripts? For example, I want to create a short script called print so that I can do some formatted printing: #!/bin/sh # Print -- formatted printer tool to get a 5-space margin and a header/footer pr -o 5 $1 | lpr When I try to run this

Re: BASH question

1998-02-13 Thread Ben Pfaff
Can anyone tell me why I can't generate working Bash scripts? Any help would be greatly appreciated. I suggest that you uuencode one of the non-working scripts and mail it to the list. It could be that some funny characters slipped in and they're confusing bash. -- TO UNSUBSCRIBE FROM

bash question ...

1997-01-18 Thread Richard G. Roberto
Are there any bash gurus out there? I have a couple of Q's. I have some scripts that run fine under bourne-shell on solaris, but break under bash on debian. The signal trapping doesn't seem to work. Nor does executing multiple commands on a single line separated by ; characters. Even on the

Re: bash question ...

1997-01-18 Thread Philippe Troin
On Sat, 18 Jan 1997 12:54:37 +0900 Richard G. Roberto ([EMAIL PROTECTED]) wrote: I have some scripts that run fine under bourne-shell on solaris, but break under bash on debian. The signal trapping doesn't seem to work. Nor does executing multiple commands on a single line separated by ;

Re: bash question ...

1997-01-18 Thread Ioannis Tambouras
bash$ xplaycd ; xmixer bash: syntax error near unexpected token `;' Indeed, sh(1) will breaks in svr4, but not in bsdi. Did not spend the time to track down the verisions thought. In debian, bash(1) version 1.14.7-2, this problem is easily solved, do: $ xplaycd xmixer Do not know about

Re: bash question ...

1997-01-18 Thread Richard G. Roberto
Well, unfortunately, I'm not really executing xplaycd in the script. The and ; work fine on SunOS, Solaris, HP/UX and Ahmdahl bourne-shells. It also works under ash. I'm tempted to just install ash as the default shell, but I would like to run bash as my login shell. Is there any way to

<    1   2