karaf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andreas Pieber <anpie...@gmail.com>
Subject Re: Text editing in the Karaf console
Date Mon, 03 Dec 2012 03:41:43 GMT
@Ioannis: That's a really great idea! You'll definitely have my Kudos for
that :-)

@Guillaume: Why unix specifc? You've e.g. edit in windows (as Ioannis
noticed).

@JB Executing native commands could be kind of dangerous. For example, just
because Karaf need some permissions to modify /etc/xyz you might don't like
your users to do so directly via Karaf (rm -rf /etc/xyz).

Kind regards,
Andreas

On Sun, Dec 2, 2012 at 10:35 PM, Jean-Baptiste Onofré <jb@nanthrax.net>wrote:

> Hi Ioannis,
>
> interesting, especially if it works with multiple platform.
>
> It could be tricky to "maintain" ;) but interesting for the users.
>
> Around the same area, I would like to add an escape character (like !) to
> execute native command directly from the Karaf shell (like !ls -l for
> instance).
>
> Regards
> JB
>
>
> On 12/02/2012 06:40 PM, Ioannis Canellos wrote:
>
>> Hi guys,
>>
>> One feature I've always liked to have in the karaf console is the ability
>> to edit text files. See https://issues.apache.org/**
>> jira/browse/KARAF-2044 <https://issues.apache.org/jira/browse/KARAF-2044>
>>
>> I took a stub last night, to integrate existing editors that might be
>> present in the system with the Karaf console (e.g. vi, nano or edit in
>> windows).
>> To my surprise starting the editor as a new Process and wiring input and
>> output seems to just work.
>>
>> There are just a few things I'd like to solve before committing and I
>> wanted some ideas:
>>
>> i) I can pass the terminal height and width to the process, but how do I
>> get those values get updated if I resize while the editor is open?
>> ii) Some editor don't take kindly the delete character and prefer
>> backspace
>> (changing ascii 127 to ascii 8). Is this safe to do. Is there a better way
>> to handle it?
>> iii) After closing the editor, the console sometimes gets "flaky" arrow
>> keys might stop working etc.
>>
>> Thoughts?
>>
>>
> --
> Jean-Baptiste Onofré
> jbonofre@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message