From: Marc Heiler Date: 2008-07-18T01:44:26+09:00 Subject: Readline and conditional tab results based on input Hi there, is there a way to "find out" what a user already typed in readline? Reason is, i am fetching user input like so: user_input = Readline.readline(' Input name of a dir, then press '+"\n",true) And with Readline.completion_proc i have code that will return only dirs in this directory. But I would like to invoke this specific code part only when a user typed in i.e. "cd " So if i have a directory called "foobar" it should work here: "cd foo" # completed to foobar but if the user would type "blabalblabla foo" # there should be no result -- Posted via http://www.ruby-forum.com/.