I have to create an interface to allow several users to perform various
tasks over ssh. The users will have different permissions.
I want to create a custom shell/CLI to be set as the users shell when they
log in. The interface should have scroll back, command line editing and
history like a normal shell. The commands would be custom commands, i.e.
no relation to system commands.
Is there any library, framework or something to make this easy with ruby?
···
--
Jesper
17:35:13 up 3 days, 20:32, 10 users, load average: 0.84, 1.21, 1.10
`readline` is part of the stdlib. It's not documented in rdoc, but
more or less trivial to use once you've looked at the examples in the
distribution.
-Tim
···
On 3/14/07, Jesper Andersen <iiLi58in@j-f.dk> wrote:
I have to create an interface to allow several users to perform various
tasks over ssh. The users will have different permissions.
I want to create a custom shell/CLI to be set as the users shell when they
log in. The interface should have scroll back, command line editing and
history like a normal shell. The commands would be custom commands, i.e.
no relation to system commands.
Is there any library, framework or something to make this easy with ruby?
--
Jesper
17:35:13 up 3 days, 20:32, 10 users, load average: 0.84, 1.21, 1.10
i would customize irb. for example
harp:~ > cat a.rb
def ls g = '*'
Dir.glob(g){|entry| puts entry}
end
def cd d = File.expand_path('~')
Dir.chdir d
end
irb:~ > irb -r ./a.rb
irb(main):001:0> ls 'skype*'
skype-1.2.0.18
skype-1.3.0.53
skype_staticQT-1.3.0.53-generic.tar.bz2
=> nil
irb(main):002:0> cd '/tmp'
=> 0
others have done this extensively - check out the raa
cheers
-a
···
On Wed, 14 Mar 2007, Jesper Andersen wrote:
I have to create an interface to allow several users to perform various
tasks over ssh. The users will have different permissions.
I want to create a custom shell/CLI to be set as the users shell when they
log in. The interface should have scroll back, command line editing and
history like a normal shell. The commands would be custom commands, i.e.
no relation to system commands.
Is there any library, framework or something to make this easy with ruby?
--
be kind whenever possible... it is always possible.
- the dalai lama