Re: Bad number of digits in brace sequence expansion when used increment

2009-08-14 Thread Roman Rakus

On 07/28/2009 04:22 PM, Roman Rakus wrote:
When we use 0 prefix and increment bash will prefix all integers with 
bad number of zeroes. Man page says "When either x or y begins with a 
zero, the shell attempts to force all generated terms to contain the 
same number of digits, zero-padding where necessary."

The number of digits is same, but not what would anyone expect.

Repeated by:
echo {1..05..1}

Actual result:
1 2 3 4 5

Desired result:
01 02 03 04 05

Patch included.
RR

Chet, what do you think about it?
RR




Re: Bad number of digits in brace sequence expansion when used increment

2009-08-14 Thread Chet Ramey
Roman Rakus wrote:
> On 07/28/2009 04:22 PM, Roman Rakus wrote:
>> When we use 0 prefix and increment bash will prefix all integers with
>> bad number of zeroes. Man page says "When either x or y begins with a
>> zero, the shell attempts to force all generated terms to contain the
>> same number of digits, zero-padding where necessary."
>> The number of digits is same, but not what would anyone expect.
>>
>> Repeated by:
>> echo {1..05..1}
>>
>> Actual result:
>> 1 2 3 4 5
>>
>> Desired result:
>> 01 02 03 04 05
>>
>> Patch included.
>> RR
> Chet, what do you think about it?

I had already fixed it a different way before the original message
appeared.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/




bash: bashref.info - Change index name from bash to bashref

2009-08-14 Thread Jari Aalto

-rw-rw-r--  1  502 root   5429 2009-03-16 18:36 bashref.info
-rw-rw-r--  1  502 root 301063 2009-03-16 18:36 bashref.info-1
-rw-rw-r--  1  502 root 128001 2009-03-16 18:36 bashref.info-2
-rw-r--r--  1 root src  117639 2009-03-16 18:40 bashref.info.tar.gz

$ install-info --debug bashref.info /usr/local/share/info/dir

$ emacs -Q -f info
m Bash 

ERROR is displayed and Bash info pages cannot be accessed:

Info-find-file: Info file bash does not exist

CORRECTION

The problems is incorrect entry in bashref.info. The following patch
fixes it.

Jari

>From 4df277d4306b8a1cdf4bc72761ab4d43aed51a84 Mon Sep 17 00:00:00 2001
From: Jari Aalto 
Date: Fri, 14 Aug 2009 21:16:54 +0300
Subject: [PATCH] bashref.info: Fix index name from 'bash' to 'bashrf'

Signed-off-by: Jari Aalto 
---
 bashref.info |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/bashref.info b/bashref.info
index 312398b..a88de09 100644
--- a/bashref.info
+++ b/bashref.info
@@ -28,7 +28,7 @@ preserved on all copies.
 
 INFO-DIR-SECTION Basics
 START-INFO-DIR-ENTRY
-* Bash: (bash). The GNU Bourne-Again SHell.
+* Bash: (bashref). The GNU Bourne-Again SHell.
 END-INFO-DIR-ENTRY
 
 
-- 
1.6.3.3



Re: bash: bashref.info - Change index name from bash to bashref

2009-08-14 Thread Chet Ramey
Jari Aalto wrote:
> -rw-rw-r--  1  502 root   5429 2009-03-16 18:36 bashref.info
> -rw-rw-r--  1  502 root 301063 2009-03-16 18:36 bashref.info-1
> -rw-rw-r--  1  502 root 128001 2009-03-16 18:36 bashref.info-2
> -rw-r--r--  1 root src  117639 2009-03-16 18:40 bashref.info.tar.gz
> 
> $ install-info --debug bashref.info /usr/local/share/info/dir

Why did you do this, instead of `make install' in the doc subdirectory?
The Makefile creates bash.info from bashref.info and installs it with
the correct name and index.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/




Re: bash: bashref.info - Change index name from bash to bashref

2009-08-14 Thread Jari Aalto
Chet Ramey  writes:

> Jari Aalto wrote:
>> -rw-rw-r--  1  502 root   5429 2009-03-16 18:36 bashref.info
>> -rw-rw-r--  1  502 root 301063 2009-03-16 18:36 bashref.info-1
>> -rw-rw-r--  1  502 root 128001 2009-03-16 18:36 bashref.info-2
>> -rw-r--r--  1 root src  117639 2009-03-16 18:40 bashref.info.tar.gz
>> 
>> $ install-info --debug bashref.info /usr/local/share/info/dir
>
> Why did you do this, instead of `make install' in the doc subdirectory?
> The Makefile creates bash.info from bashref.info and installs it with
> the correct name and index.

According to:

http://www.gnu.org/software/bash/manual/

- Info document (120K bytes gzipped tar file).

Downloading and install_

wget http://www.gnu.org/software/bash/manual/bashref.info.tar.gz
tar -xf *.gz
ls -la
-rw-r--r--  1 foo foo   5429 2009-03-16 18:36 bashref.info
-rw-r--r--  1 foo foo 301063 2009-03-16 18:36 bashref.info-1
-rw-r--r--  1 foo foo 128001 2009-03-16 18:36 bashref.info-2
-rw-r--r--  1 foo foo 117639 2009-03-16 18:40 bashref.info.tar.gz

There is no Makefile; what would be the appropriate contact to fix this?

Jari





Re: bash: bashref.info - Change index name from bash to bashref

2009-08-14 Thread Chet Ramey
Jari Aalto wrote:

>> Jari Aalto wrote:
>>> -rw-rw-r--  1  502 root   5429 2009-03-16 18:36 bashref.info
>>> -rw-rw-r--  1  502 root 301063 2009-03-16 18:36 bashref.info-1
>>> -rw-rw-r--  1  502 root 128001 2009-03-16 18:36 bashref.info-2
>>> -rw-r--r--  1 root src  117639 2009-03-16 18:40 bashref.info.tar.gz
>>>
>>> $ install-info --debug bashref.info /usr/local/share/info/dir
>> Why did you do this, instead of `make install' in the doc subdirectory?
>> The Makefile creates bash.info from bashref.info and installs it with
>> the correct name and index.
> 
> According to:
> 
> http://www.gnu.org/software/bash/manual/
> 
> - Info document (120K bytes gzipped tar file).
> 
> Downloading and install_
> 
> wget http://www.gnu.org/software/bash/manual/bashref.info.tar.gz
> tar -xf *.gz
> ls -la
> -rw-r--r--  1 foo foo   5429 2009-03-16 18:36 bashref.info
> -rw-r--r--  1 foo foo 301063 2009-03-16 18:36 bashref.info-1
> -rw-r--r--  1 foo foo 128001 2009-03-16 18:36 bashref.info-2
> -rw-r--r--  1 foo foo 117639 2009-03-16 18:40 bashref.info.tar.gz
> 
> There is no Makefile; what would be the appropriate contact to fix this?

I don't know.  I didn't really have anything to do with making that
available, or with that web site.  Maybe g...@gnu.org?

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/