[asterisk-bugs] [Asterisk 0012390]: [patch] some fixes to astcli

noreply at bugs.digium.com noreply at bugs.digium.com
Wed Apr 9 02:26:15 CDT 2008


The following issue has been UPDATED. 
====================================================================== 
http://bugs.digium.com/view.php?id=12390 
====================================================================== 
Reported By:                tzafrir
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   12390
Category:                   General
Reproducibility:            always
Severity:                   tweak
Priority:                   normal
Status:                     new
Asterisk Version:           SVN 
SVN Branch (only for SVN checkouts, not tarball releases):  trunk 
SVN Revision (number only!): 113646 
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             04-09-2008 01:54 CDT
Last Modified:              04-09-2008 02:26 CDT
====================================================================== 
Summary:                    [patch] some fixes to astcli
Description: 
A number of fixes to astcli:

1. the script lacks a license terms stanza.

2. The script will die if a certain configuration file does not exist. So
I can't just copy it to a system and use it. If I don't happen to have
write permissions to /etc/asterisk I can't use it at all.

Fix: don't die. Just ignore that file.

3. Configuration file names under /etc should not be hidden . The reason
configuration files under the home directory are hidden are to avoid
cluttering it. But in /etc configuration files are not a clutter.

Think of the sysadmin who is used to backup his /etc/asterisk using 'cp -a
/etc/asterisk/* /target/dir/'

Fix: Change the global configuration file name to
/etc/asterisk/astcli.conf . 

However: 
A. This file does not follow the syntax of Asterisk's configuration files
(no [header])
B. We already have /etc/asterisk/asterisk-cli.conf

3. The script has useful output. Thus the help text should go to standard
error.

4. Parse global config first, user config later and then command-line
arguments.

And while we're at it, allow commands from standard input.
====================================================================== 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
04-09-08 02:26  tzafrir        Description Updated                          
======================================================================




More information about the asterisk-bugs mailing list