Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.sys.mac.system > #78783

Re: Bash Script Problem

Path csiph.com!au2pb.net!feeder.erje.net!1.eu.feeder.erje.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From Jolly Roger <jollyroger@pobox.com>
Newsgroups comp.sys.mac.system
Subject Re: Bash Script Problem
Date 22 Aug 2015 19:59:38 GMT
Organization People for the Ethical Treatment of Pirates
Lines 28
Message-ID <d3s2laFehv8U1@mid.individual.net> (permalink)
References <1m9k0ik.l4day0m0szjaN%csampson@inetworld.net>
X-Trace individual.net o9w7czzR5UHxtpKYPqlOVA1l/gjJFPwi1xnBfonWJ5DTgelDJn
Cancel-Lock sha1:GVfUicMNK82rzo9/LC+FZJ4okGQ=
X-Face _.g>n!a$f3/H3jA]>9pN55*5<`}Tud57>1<n@LQ!aZ7vLO_nWbK~@T'XIS0,oAJcU.qLM dk/j8Udo?O"o9B9Jyx+ez2:B<nx(k3EdHnTvB]'eoVaR495,Rv~/vPa[e^JI+^h5Zk*i`Q;ezqDW< ZFs6kmAJWZjOH\8[$$7jm,Ogw3C_%QM'|H6nygNGhhl+@}n30Nz(^vWo@h>Y%b|b-Y~()~\t,LZ3e up1/bO{=-)
User-Agent slrn/1.0.1 (Darwin)
Xref csiph.com comp.sys.mac.system:78783

Show key headers only | View raw


On 2015-08-22, Charles H. Sampson <csampson@inetworld.net> wrote:
> I'm having a problem with a Bash script. I've spent a lot of time on it
> and I'm very frustrated. I'm sure I'm going to be more upset when I find
> out what the solution is.
>
> Here are the first few lines of the scipt:
>
>    #!/bin/bash
>    logfile="file-name-wth-complete-path-containing-no-spaces"
>    datetime=`date +"%y/%m/%d %H:%M:%S"`
>    echo $datetime script started >> $logfile
>
> The problem is that the startup message doesnt get put to the logfile.

Interesting. I ran the above code, with no modifications, and a file
named "file-name-wth-complete-path-containing-no-spaces" was created on
my desktop containing:

15/08/22 12:58:37 script started

If you run the above code without any modifications, do you see the same
result?

-- 
E-mail sent to this address may be devoured by my ravenous SPAM filter.
I often ignore posts from Google. Use a real news client instead.

JR

Back to comp.sys.mac.system | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Bash Script Problem csampson@inetworld.net (Charles H. Sampson) - 2015-08-22 11:55 -0700
  Re: Bash Script Problem JF Mezei <jfmezei.spamnot@vaxination.ca> - 2015-08-22 15:18 -0400
  Re: Bash Script Problem Jolly Roger <jollyroger@pobox.com> - 2015-08-22 19:59 +0000
    Re: Bash Script Problem Alan Baker <email@domain.com> - 2015-08-23 00:53 -0700
  Re: Bash Script Problem Barry Margolin <barmar@alum.mit.edu> - 2015-08-22 18:48 -0400
    Re: Bash Script Problem Jolly Roger <jollyroger@pobox.com> - 2015-08-23 00:44 +0000
  Re: Bash Script Problem csampson@inetworld.net (Charles H. Sampson) - 2015-08-22 23:22 -0700
    Re: Bash Script Problem Huge <Huge@nowhere.much.invalid> - 2015-08-23 08:13 +0000
    Re: Bash Script Problem Barry Margolin <barmar@alum.mit.edu> - 2015-08-24 05:15 -0400

csiph-web