Fix option and configuration for 'extra_tag_file'

Option was documented but did not work correctly.

Github issue #51
This commit is contained in:
Duncan Ferguson 2016-01-23 17:02:52 +00:00
parent 7e55006acd
commit c5c2c4fc0e
5 changed files with 14 additions and 4 deletions

View file

@ -1,5 +1,6 @@
4.05_01 0000-00-00 Duncan Ferguson <duncan_ferguson@user.sf.net>
- Failure to find the terminal binary should not be fatal
- Fix processing of '--extra_tag_file' and its configuration item (Github issue #51)
4.05 2015-11-28 Duncan Ferguson <duncan_ferguson@user.sf.net>
- Change default key_quit from 'Control-q' to 'Alt-q' (Github issue #50)

View file

@ -74,6 +74,7 @@ my %default_config = (
sftp => 'sftp',
sftp_args => "",
extra_tag_file => '',
extra_cluster_file => '',
external_cluster_command => '',
@ -186,10 +187,8 @@ sub validate_args {
# check the terminal has been found correctly
# looking for the terminal should not be fatal
if ( !-e $self->{terminal} ) {
eval {
$self->{terminal} = $self->find_binary( $self->{terminal} );
};
if($@) {
eval { $self->{terminal} = $self->find_binary( $self->{terminal} ); };
if ($@) {
warn $@->message;
}
}

View file

@ -646,6 +646,13 @@ If the external command is given a C<-L> option it should output a list of tags
);
output 'C<< extra_cluster_file = ~/clusters, $HOME/clus >>';
output '=item extra_tag_file = <null>';
output $self->loc(
q{Define an extra tag file in the format of [_1]. Multiple files can be specified, separated by commas. Both ~ and $HOME are acceptable as a reference to the user's home directory, e.g.},
'F</etc/tags>'
);
output 'C<< extra_tag_file = ~/tags, $HOME/tags >>';
output '=item key_addhost = Control-Shift-plus';
output $self->loc(
q{Default key sequence to open AddHost menu. See [_1] for more information.},

View file

@ -79,6 +79,7 @@ Readonly::Hash my %default_config => {
sftp => 'sftp',
sftp_args => "",
extra_tag_file => "",
extra_cluster_file => "",
external_cluster_command => '',
@ -533,6 +534,7 @@ console_position=
debug=0
external_cluster_command=
extra_cluster_file=
extra_tag_file=
history_height=10
history_width=40
key_addhost=Control-Shift-plus

View file

@ -5,6 +5,7 @@ command=
comms=ssh
console_position=
extra_cluster_file=
extra_tag_file=
history_height=10
history_width=40
key_addhost=Control-Shift-plus