PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Serveur - Sécurité et techniques > comp.unix.shell > bash: How to use 'set -o vi' and still be able to use ctrl-a, ctrl-e etc.
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.unix.shell Using and programming the Unix shell.

bash: How to use 'set -o vi' and still be able to use ctrl-a, ctrl-e etc.

Réponse
 
LinkBack Outils de la discussion
Vieux 25/05/2007, 09h29   #1
Erik Terpstra
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut bash: How to use 'set -o vi' and still be able to use ctrl-a, ctrl-e etc.

Is it possible to use VI mode in bash and still be able to use ctrl-a,
ctrl-e, ctrl-l and ctrl-w like they work in Emacs mode? These key
sequences are hard wired into my brain after using emacs mode in the
shell for such a long time.

Most ctrl-<key> sequences don't seem to conflict with the VI key
sequences, is it possible to make them available in the VI mode?

TIA,

Erik.

  Réponse avec citation
Vieux 25/05/2007, 10h30   #2
Martin Krischik
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: bash: How to use 'set -o vi' and still be able to use ctrl-a,ctrl-e etc.

Erik Terpstra schrieb:
> Is it possible to use VI mode in bash and still be able to use ctrl-a,
> ctrl-e, ctrl-l and ctrl-w like they work in Emacs mode? These key
> sequences are hard wired into my brain after using emacs mode in the
> shell for such a long time.
>
> Most ctrl-<key> sequences don't seem to conflict with the VI key
> sequences, is it possible to make them available in the VI mode?


Well, I did something similar for Z-Shell [1] - basily by remapping the
keys after activating the vi mode. AFAIK in bash the .inputrc file is
used for that purpose.

I would suggest you create a .inputrc (there is a tool the generate an
initial version) for emacs and for vi mode and then compare them. That
is the way I did if for Z-Shell.

Martin

[1] http://martin.krischik.com/index.php/Z-Shell/VimMode
--
Martin Krischik
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 21h03.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,06682 seconds with 10 queries