tag:blogger.com,1999:blog-3599722177679860131.post7390098581007662384..comments2024-01-03T10:01:29.738+01:00Comments on Chemical Quantum Images: using "tee" for interactive input generationFelixhttp://www.blogger.com/profile/05138335803929997277noreply@blogger.comBlogger5125tag:blogger.com,1999:blog-3599722177679860131.post-36453282449655097522011-01-20T18:37:18.244+01:002011-01-20T18:37:18.244+01:00I realized and my idea was to use it in the first ...I realized and my idea was to use it in the first task, namely 'tee define.in | define'. So that you don't have any nasty symbols in define.in<br /><br />What I realized just now is that this does _not_ work in conjunction with rlwrap.<br /><br />Sorry for being a little bit overzealous here...fuulishhttps://www.blogger.com/profile/10151529909424605946noreply@blogger.comtag:blogger.com,1999:blog-3599722177679860131.post-37129265403366693332011-01-20T18:24:08.197+01:002011-01-20T18:24:08.197+01:00ok, i see.
for this specific purpose I wanted to ...ok, i see.<br /><br />for this specific purpose I wanted to avoid the interactive input alltogether and just type<br />"define < define.in"<br /><br />but it is definitely a nice tool to have lrwrap in other cases. I often catch myself typing \tab and producing weird signs in the program...Felixhttps://www.blogger.com/profile/05138335803929997277noreply@blogger.comtag:blogger.com,1999:blog-3599722177679860131.post-41422488070815910532011-01-20T18:09:37.516+01:002011-01-20T18:09:37.516+01:00Okay, you called define and you're typing your...Okay, you called define and you're typing your input. Except for using backspace to delete some of the input, you can't really edit what you just typed. rlwrap uses the GNU readline library to take care of the latter task so that you are able to edit your keyboard input within define. Additionally, you have the possibility to create and edit a file named $HOME/.define_completions for the lazy people among us who enjoy tab-completion (this file just contains a list of words that will be used as options for completing your input)<br /><br />There are also a .define_history and .definerc file for a history and default settings. Although I never used the latter one in any specific matter.<br /><br />A somewhat analogous comparison would be sh vs bash (although not a very thorough comparison)<br /><br />Hope that makes it more clear.fuulishhttps://www.blogger.com/profile/10151529909424605946noreply@blogger.comtag:blogger.com,1999:blog-3599722177679860131.post-19943643338374376212011-01-20T17:26:54.765+01:002011-01-20T17:26:54.765+01:00thanks, I'll try it out. but I haven't rea...thanks, I'll try it out. but I haven't really understood yet what it doesFelixhttps://www.blogger.com/profile/05138335803929997277noreply@blogger.comtag:blogger.com,1999:blog-3599722177679860131.post-70141359526745747512011-01-20T16:33:28.570+01:002011-01-20T16:33:28.570+01:00Very nice, never considered doing this with 't...Very nice, never considered doing this with 'tee'. Thanks.<br /><br />Just fyi, it can be very bothering to work with define, because you are not able to edit your input lines. By using rlwrap (a readline wrapper) you can edit your input line, have tab-completion and create a history.<br />rlwrap is afaik included in the repos of the major LINUX distributions, thus easy to intall. If done so, it's just 'rlwrap define' and you're good to go...<br /><br />Hope this is helpful for you,<br /><br />cheers Frankfuulishhttps://www.blogger.com/profile/10151529909424605946noreply@blogger.com