Sean Higgins | 1 Feb 2006 21:35

ssh Completion Problems


Hello,

Is anybody having problems with ssh command completion?  I type:

ssh <tab>

And fish just crashes with a segmentation fault.  It used to work at one time, 
I am not sure if this is a new problem in 1.20.1 or not.  Everything else 
seems to be working.

Any suggestions on trouble shooting?

Sean

--

-- 
Sean Higgins, sean@...
http://www.systura.com - "Where information becomes knowledge."

-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
Nick Pilon | 1 Feb 2006 21:50
Picon

Re: ssh Completion Problems

On 2/1/06, Sean Higgins <sean <at> systura.com> wrote:
> Is anybody having problems with ssh command completion?  I type:
>
> ssh <tab>
> Any suggestions on trouble shooting?

Dunno if it helps, but here's what I get:

sed: 1: "y/\t/\n/
": transform strings are not the same length
cat: /etc/fstab: No such file or directory
sed: 1: "y/\t/\n/
": transform strings are not the same length
cat: /etc/fstab: No such file or directory
npilon <at> Sharron-Apple ~> ssh

\#\ mode.\ \ At\ other\ times\ this\ information\ is\ handled\ by\   (Hostname)
\#\ not\ be\ consulted\ unless\ you\ have\ changed\ lookupds\ confi  )
\#\ Note\ that\ this\ file\ is\ consulted\ when\ the\ system\ is\ r  (Hostname)
\#\ This\ file\ is\ used\ while\ in\ single\ user\ mode. <at>              (Hostname)
\#\ To\ use\ this\ file\ for\ normal\ authentication,\ you\ may\ en  (Hostname)
\#\ User\ Database <at>                                                    (Hostname)
\#\# <at>                                                                  (Hostname)
\# <at>                                                                    (Hostname)
(List of hosts here)

Then, if one pages to the end of the list of hosts, one gets a SIGBUS.

Hm. Are you on Mac OS X too, by any chance? It doesn't seem to have an fstab.

(Continue reading)

Axel Liljencrantz | 2 Feb 2006 01:04
Picon

Re: ssh Completion Problems

2006/2/1, Sean Higgins <sean <at> systura.com>:
>
> Hello,
>
> Is anybody having problems with ssh command completion?  I type:
>
> ssh <tab>
>
> And fish just crashes with a segmentation fault.  It used to work at one time,
> I am not sure if this is a new problem in 1.20.1 or not.  Everything else
> seems to be working.

I can not reproduce this. The only significant recent update to the
ssh completions is the i18n support added with 1.20.0. Can you do some
further testing on this problem? Perhaps run fish inside of Valgrind
and try to trigger the crash? To get the most out of a Valgrind
session, you'll need to compile fish with debug symbols.

>
> Any suggestions on trouble shooting?
>
> Sean
>
> --
> Sean Higgins, sean <at> systura.com
> http://www.systura.com - "Where information becomes knowledge."
>

--
Axel
(Continue reading)

Frederik 'Freso' S. Olesen | 2 Feb 2006 12:17
Picon

Re: using && and || instead of 'and' & 'or'

2006/1/5, Isak Savo <isak.savo@...>:
>2006/1/5, Axel Liljencrantz <liljencrantz@...>:
<zap>
>> Reasons why I feel and is better than &&:
>>
>> * Smaller syntax with fewer special syntaxes
>> * Easier to learn if you're new to scripting, since you can find out about
>>it through tab completion
>> * The syntax is more closely related to the 'if' syntax
>
>Good points, although the "easier to learn" point is double sided.
>Anyone with previous programming/scripting knowledge understands the
>'and' operator to be, well, an operator and not a command. Having it
>as a builtin makes it inconsistent with most other
>scripting/programming languages (which may or may not be a good thing,
>depending on your design goals)

Python uses "and" and "or" instead of "&&" and "||", just for the
record, and it really just comes down to a matter of habit, I think.
:) (Although I suppose it's still an operator in Python and not a
command.)
And for people who are used to programming, it shouldn't take much
effort to replace &&/|| with (; )and/or, IMHO.

ps. Yay for month-old replies...
--
Frederik 'Freso' S. Olesen <http://freso.dk/>

-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
(Continue reading)

Christopher Pinon | 2 Feb 2006 18:02

Re: problem compiling fish on an older system

Hi,

I just wanted to give an update on compiling fish on an older system 
(Slackware 8.0, from 2001). Following Egon's tip, I upgraded gcc from 
gcc-2.95.3 to gcc-3.2.3 and as a result fish now happily compiles (with 
glibc-2.2.3 and doxygen-1.2.18).

Unfortunately, though, whenever I try to start fish I get the following 
error message:

pinon <at> newton~$ fish
fish: Co
StandardWelcome to fish, the friendly interactive shell
Type help for instructions on how to use fish
set_color: Expected an argument
pinon <at> newton set_color - Set the terminal color       \section 
set_color-synopsis  set_color [-v --version] [-h       --help] [-b 
--background COLOR] [COLOR]>  <at>        \section set_color-description        
Change the foreground and/or background color of the       terminal. 
COLOR is one of black, red, green, brown,>        yellow, blue, magenta, 
purple, cyan, white and normal. <at>         -c, --print-colors Prints a list 
of all valid color names       -b, --background Set the background 
color>  <at>        -o, --bold Set bold or extra bright mode        -h, 
--help Display help message and exit>        -v, --version Display 
version and exit <at>         Calling set_color normal will set the terminal 
color to       whatever is the default color of the terminal.>        
Some terminals use the --bold escape sequence to switch to <at>        a 
brighter color set. On such terminals, set_color white        will 
result in a grey font color, while set_color --bold       white will 
result in a white font color.> ~ <at>  > 
(Continue reading)

Axel Liljencrantz | 2 Feb 2006 18:02
Picon

Re: ssh Completion Problems

2006/2/1, Nick Pilon <npilon <at> gmail.com>:
>

Hi Nick,

For some reason your mail came up empty in my reader. It seems some of
my mails have done the same to some people. Maybe it is a gmail
problem?  Anyway, your response showed in the sourceforge archives, so
I managed to find it anyway.

I have changed the fish completion code to check if /etc/hosts and
/etc/fstab exist instead of blindly opening them. I've also replaced
the sed call in your message with a call to tr, hopefully that will
solve the sed problem. Seems sed interprets backslash escapes
differently on different platforms.

What program gets the SIGBUS? Fish itself or the pager command? Or is
it listed as a completion?

--
Axel
NHY޵隊X'u[
ަk!W~鮆zkC	塧m <at> ^ǚ^zZfzj!x2ɫ,a{,H4mZjYwǥrg <at> y$5~7ٸmΝj5^
Axel Liljencrantz | 2 Feb 2006 17:46
Picon

Re: using && and || instead of 'and' & 'or'

2006/2/2, Frederik 'Freso' S. Olesen <freso.dk <at> gmail.com>:
> 2006/1/5, Isak Savo <isak.savo <at> gmail.com>:
> >2006/1/5, Axel Liljencrantz <liljencrantz <at> gmail.com>:
> <zap>
> >> Reasons why I feel and is better than &&:
> >>
> >> * Smaller syntax with fewer special syntaxes
> >> * Easier to learn if you're new to scripting, since you can find out about
> >>it through tab completion
> >> * The syntax is more closely related to the 'if' syntax
> >
> >Good points, although the "easier to learn" point is double sided.
> >Anyone with previous programming/scripting knowledge understands the
> >'and' operator to be, well, an operator and not a command. Having it
> >as a builtin makes it inconsistent with most other
> >scripting/programming languages (which may or may not be a good thing,
> >depending on your design goals)
>
> Python uses "and" and "or" instead of "&&" and "||", just for the
> record, and it really just comes down to a matter of habit, I think.
> :) (Although I suppose it's still an operator in Python and not a
> command.)
> And for people who are used to programming, it shouldn't take much
> effort to replace &&/|| with (; )and/or, IMHO.

Especially given the following error message when you slip up and use
Posix syntax:

fish> make || make clean
fish: Expected a command name, got token of type 'Pipe'. Did you mean
(Continue reading)

Axel Liljencrantz | 2 Feb 2006 18:20
Picon

Re: problem compiling fish on an older system

2006/2/2, Christopher Pinon <pinon <at> sdf-eu.org>:
> Hi,
>
> I just wanted to give an update on compiling fish on an older system
> (Slackware 8.0, from 2001). Following Egon's tip, I upgraded gcc from
> gcc-2.95.3 to gcc-3.2.3 and as a result fish now happily compiles (with
> glibc-2.2.3 and doxygen-1.2.18).
>
> Unfortunately, though, whenever I try to start fish I get the following
> error message:
>
>
> pinon <at> newton~$ fish
> fish: Co
> StandardWelcome to fish, the friendly interactive shell
> Type help for instructions on how to use fish
> set_color: Expected an argument
> pinon <at> newton set_color - Set the terminal color       \section
> set_color-synopsis  set_color [-v --version] [-h       --help] [-b
> --background COLOR] [COLOR]>  <at>        \section set_color-description
> Change the foreground and/or background color of the       terminal.
> COLOR is one of black, red, green, brown,>        yellow, blue, magenta,
> purple, cyan, white and normal. <at>         -c, --print-colors Prints a list
> of all valid color names       -b, --background Set the background
> color>  <at>        -o, --bold Set bold or extra bright mode        -h,
> --help Display help message and exit>        -v, --version Display
> version and exit <at>         Calling set_color normal will set the terminal
> color to       whatever is the default color of the terminal.>
> Some terminals use the --bold escape sequence to switch to <at>        a
> brighter color set. On such terminals, set_color white        will
(Continue reading)

Nick Pilon | 2 Feb 2006 18:19
Picon

Re: ssh Completion Problems

On 2/2/06, Axel Liljencrantz <liljencrantz <at> gmail.com> wrote:
> For some reason your mail came up empty in my reader. It seems some of
> my mails have done the same to some people. Maybe it is a gmail
> problem?  Anyway, your response showed in the sourceforge archives, so
> I managed to find it anyway.

Your messages have been doing the same thing to me sporadically,
though never on ones that are addressed to me. I'm not entirely sure
why. gmail's "show original" produces a block of what I can only
describe as odd-looking garbage.

> What program gets the SIGBUS? Fish itself or the pager command? Or is
> it listed as a completion?

It's definitely the pager command. What I actually get is:

fish: Job 0, 'fish_pager 0 "" \#\ /Applications/Utilities/Directory\
Access. <at> \x04Hostname \#\  <at> \x04Hostname \#\ By\ default,\ lookupd\
gets\ information\ from\ NetInfo,\ so\ this\ file\ will\  <at> \x04Hostname
\#\ lookupd\ DirectoryServices\ \  <at> \x04Hostname \#\ mode.\ \ At\
other\ times\ this\ information\ is\ handled\ by\ one\ or\ more\
of <at> \x04Hostname \#\ not\ be\ consulted\ unless\ you\ have\ changed\
lookupds\ configuration. <at> \x04Hostname \#\ Note\ that\ this\ file\ is\
consulted\ when\ the\ system\ is\ running\ in\
single-user <at> \x04Hostname \#\ This\ file\ is\ used\ while\ in\ single\
user\ mode. <at> \x04Hostname \#\ To\ use\ this\ file\ for\ normal\
authentication,\ you\ may\ enable\ it\ with <at> \x04Hostname \#\ User\
Database <at> \x04Hostname \#\# <at> \x04Hostname \# <at> \x04Hostname (whole bunch
of other completions)' terminated by signal SIGBUS (Misaligned address
error)
(Continue reading)

Axel Liljencrantz | 2 Feb 2006 18:30
Picon

Re: ssh Completion Problems

2006/2/2, Nick Pilon <npilon <at> gmail.com>:
> On 2/2/06, Axel Liljencrantz <liljencrantz <at> gmail.com> wrote:
> > For some reason your mail came up empty in my reader. It seems some of
> > my mails have done the same to some people. Maybe it is a gmail
> > problem?  Anyway, your response showed in the sourceforge archives, so
> > I managed to find it anyway.
>
> Your messages have been doing the same thing to me sporadically,
> though never on ones that are addressed to me. I'm not entirely sure
> why. gmail's "show original" produces a block of what I can only
> describe as odd-looking garbage.
>
> > What program gets the SIGBUS? Fish itself or the pager command? Or is
> > it listed as a completion?
>
> It's definitely the pager command. What I actually get is:
>
> fish: Job 0, 'fish_pager 0 "" \#\ /Applications/Utilities/Directory\
> Access. <at> \x04Hostname \#\  <at> \x04Hostname \#\ By\ default,\ lookupd\
> gets\ information\ from\ NetInfo,\ so\ this\ file\ will\  <at> \x04Hostname
> \#\ lookupd\ DirectoryServices\ \  <at> \x04Hostname \#\ mode.\ \ At\
> other\ times\ this\ information\ is\ handled\ by\ one\ or\ more\
> of <at> \x04Hostname \#\ not\ be\ consulted\ unless\ you\ have\ changed\
> lookupds\ configuration. <at> \x04Hostname \#\ Note\ that\ this\ file\ is\
> consulted\ when\ the\ system\ is\ running\ in\
> single-user <at> \x04Hostname \#\ This\ file\ is\ used\ while\ in\ single\
> user\ mode. <at> \x04Hostname \#\ To\ use\ this\ file\ for\ normal\
> authentication,\ you\ may\ enable\ it\ with <at> \x04Hostname \#\ User\
> Database <at> \x04Hostname \#\# <at> \x04Hostname \# <at> \x04Hostname (whole bunch
> of other completions)' terminated by signal SIGBUS (Misaligned address
(Continue reading)


Gmane