- When you have to send a control sequence/character to programs like Ctrl-C or Esc and you don't have an editor that allows you to put them directly in your script you can send the octal equivalent. Tcl provides a way of encoding using octal or hex. For example to send the Esc character you would use send "\033". To find the octal number for any key use the program od. Start it with "od -c". Press the function key you want to know about. Then hit return. Lastly, press Ctrl-D. The string between the 0000000 and \n is what you want. You could also try it this way: Type "echo " on the command line. Then Ctrl-V, then the key you want to see (lets say Ctrl-C). Then it will print ^C. After that put "|od -cb". This will print out the octal code between 0000000 and \n like before. Ctrl-C is octal 003.
niedziela, 9 czerwca 2013
Escape chars
Subskrybuj:
Komentarze do posta (Atom)
Ginekolog dr n. med. Piotr Siwek
Gabinet ginekologiczny specjalista ginekolog - położnik dr n. med. Piotr Siwek
-
8GB = memory=8589934592 python pgtune \ -i /etc/postgresql/ 9.2 /main/postgresql.conf \ -o postgresql.conf \ --memory=858993...
-
http://www.tcpdump.com/kb/os/linux/lvm-attributes/intro.html LVM Attributes 1 2 3 4 5 (10 votes, average 4.80 out of ...
-
Problem solved ;) Client tool's installer does not provide all the required libraries, so the message: " sawjniapi643r.dll: Can&...
Brak komentarzy:
Prześlij komentarz