Text Tools Mai 2012/IRC Log

aus Metalab Wiki, dem offenen Zentrum für meta-disziplinäre Magier und technisch-kreative Enthusiasten.
Version vom 9. Juni 2012, 17:22 Uhr von Thp (Diskussion | Beiträge) (Die Seite wurde neu angelegt: „IRC-Log zu Text Tools Mai 2012 ---- <pre> 16:52 < SvenG> reminder: 18h texttools meetup 16:53 < luto> ach? *diesen* samstag? 16:54 < luto> hoffentlich ma…“)
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Zur Navigation springenZur Suche springen
Die druckbare Version wird nicht mehr unterstützt und kann Darstellungsfehler aufweisen. Bitte aktualisiere deine Browser-Lesezeichen und verwende stattdessen die Standard-Druckfunktion des Browsers.

IRC-Log zu Text Tools Mai 2012


16:52 < SvenG> reminder: 18h texttools meetup
16:53 < luto> ach? *diesen* samstag?
16:54 < luto> hoffentlich macht mein lappy das noch mit :D
17:07 <+thp> hey ho
17:55 < luto> na, SvenG wo steckst?
17:55 < luto> thp: bist du im lab?
17:58 <+thp> luto: mach mich gleich auf dem weg
17:58 <+thp> luto: sollte in ~ 10-15 minuten dort sein
17:58 < luto> thp: ich bin im hauptraum^^
17:58 < luto> k
18:09 < SvenG> meep
18:09 < SvenG> so.. habe nun meine kiste
18:09 < SvenG> komme rüber
18:09 < SvenG> ca 20min
18:36 < fantazo> bitte den guckes anbinden. ich mache mich auf den Weg zu seinem Texttools #Flausch
18:46 < SvenG> re :)
18:46 < luto> wb
18:47 < SvenG> merci :)
18:47 < SvenG> so.. samm tsua driit, geh?
18:54 < SvenG> texttools session started
18:54 <+thp> Frage: zsh - wie kann man nach einer Installation das "rehash" vermeiden / automatisieren?
18:57 <+thp> alias agi='sudo apt-get install'
18:57 < SvenG> genau... alias machen.  das ist der eine weg.
18:58 < SvenG> alias rh=rehash
18:58 <+thp> ^ wie kann ich bei dem alias oben das rehash hinzufügen? (d.h. sudo apt-get install <alle anderen parameter>; rehash)
18:58 < SvenG> aber nicht viele funktionen machen, sondern lieber daraus ein habit machen
18:58 < SvenG> einfach das ding mal ruafrufen
18:58 < SvenG> alias foo=bar;rehash
18:59 < SvenG> alias expansion...
19:00 < SvenG> alias foo='cmd par1 par2'
19:01 < SvenG> $ foo bar
19:01 < SvenG> -> cmd par1 par2 bar
19:04 < SvenG> hey fionn` :)
19:04 < fionn`> hi Sven
19:06 < SvenG> Pasword Generators: apg, gpw, pwgen, makepasswd
19:20 <+thp> shared screen session via schmiede@aquarius.uberspace.de, passwort vor ort erfragen
19:22 < SvenG> ectl: TERM=xterm
19:30 < SvenG> bash... *welche* bash? -> c-x c-v
19:35 <+thp> diskussion: was benutzen zum mitloggen von terminal sachen?
19:36 <+thp> zB "script" -> kann aber problematisch sein wenn man screen verwendet (dann entweder "innerhalb" verwenden, aber man verliert window switching, etc..)
19:37 <+thp> andere alternative: screencasting-tool, zB "recordmydesktop" oder "istanbul"" unter linux
19:38 <+thp> environment variablen editieren in zsh: vared PATH
19:40 <+thp> screen neues window erstellen: C-a c ("create")
19:41 <+thp> screen window title/name aendern: C-a A
19:41 < SvenG> noch mein dickes screenrc dazu: www.guckes.net/Setup/screenrc (*viele* kommentare)
19:42 < fionn`> Warum haben wir kein statusline?
19:43 < fionn`> in meine eigne .screenrc "heardstatus alwayslastline"
19:43 < fionn`> hardstatus
19:43 <+thp> die nummer des aktuellen fensters neu setzen: C-a :number 9 (aktuelles fenster bekommt die nummer 9)
19:44 < SvenG> changing windows in screen: c-a n + c-a p  fuer next/previous window
19:45 < SvenG> command :next and :previous
19:45 <+thp> "go back to last screen": C-a C-a
19:46 <+thp> next and previous refers to the window number (+wrapping), missing numbers are simply skipped (3, no window 4, 5 -> 3 next goes to 5)
19:46 < fantazo> #flausch
19:47 < fantazo> irgendein problem: c-a w
19:48 < fantazo> ahja, wie man in screen die fensterliste anzeigt
19:48 <+thp> frage: wie kann man die ausgabe des kommandos C-a w in der statusleiste statt in der xterm titelleiste anzeigen?
19:51 < fantazo> und bunt
19:51 <+thp> screenrc in einer laufenden screen session laden: C-a :source $HOME/.screenrc
19:54 <+thp> vim: alle kommentar-zeilen löschen als beispiel für global: :g/^#/d
19:54 <+thp> also: :g / <regular expression> / <kommando>
19:56 <+thp> redo in vim: C-r (redo), geht auch mit number prefix (100 C-r)
19:57 <+thp> seit vim 7: undo/redo "branches" -> verhindert sachen, wo die history verschwindet, wenn man zB nach vielen undos ein kommando ausführt
19:57 <+thp> :help undo-branches
19:58 <+thp> unter debian ist das "volle" vim (glaub ich) normal vim-nox
19:59 <+thp> (nox steht für "no X" - d.h. alle sachen außer X UI) - ansonsten vim-gtk
20:00 < SvenG> vim -X
20:00 < SvenG> ... fuer non-X support
20:01 <+thp> wenn man GUI / clipboard haben will: gvim benutzen
20:02 < SvenG> vim with cliboard support -> use clipboard register
20:03 <+thp> thema: register unter vim
20:04 <+thp> ich verwende immer C-r " wenn ich etwas geyanked hab und es zB in "/"-suche einfügen will
20:04 < SvenG> use of registers...
20:05 <+thp> default register -> dd (zeile löschen), p (paste)
20:05 <+thp> named registers -> a-z
20:05 < SvenG> statt dd (zeile loeschen) nimmt man "xdd fuer "use register 'x' for dd"
20:06 < SvenG> pasting from register x:  "xp
20:06 <+thp> " = use a register, x = register, p = aktion
20:06 < SvenG> register for clipboard: +
20:06 < SvenG> "+dG
20:07 <+thp> + = X clipboard (wenn aktiviert)
20:08 <+thp> coole sache :)
20:08 <+thp> also einfügen vom X clipboard in insert oder command mode: C-r +
20:10 <+thp> nicht "command mode", sondern "command line mode" oder "search mode"
20:10 < SvenG> genauer: ctrl-r im *insert mode*
20:10 < SvenG> in vim speak: i_CTRL-T
20:10 <+thp> ctrl-r im normalen mode ist "redo"
20:10 < SvenG> oops
20:10 < SvenG> in vim speak: i_CTRL-R
20:10 < SvenG> -> :help i_CTRL-R
20:13 <+thp> wenn man beim einfügen probleme mit auto-indentation hat: :set paste
20:13 <+thp> (gilt für den insert mode)
20:13 < SvenG> "+p
20:13 < SvenG> besser.  kein autoindent etc.
20:14 <+thp> "+p = "use a register", "use the clipboard", "paste"
20:14 < SvenG> problem with pasting: autoexpandion of words
20:14 < SvenG> :iab foo BARBARBABR
20:15 <+thp> was mache ich, wenn in meiner vim session keine connection zu meinem X server ist, und ich trotzdem pasten will, und zwar ohne input appreviations?
20:16 <+thp> antwort: :set paste macht normal "das richtige"
20:17 <+thp> d.h. mit ":set paste" kann man "sicher" in den insert mode pasten ohne die nebeneffekte
20:18 < SvenG> right
20:20 < SvenG> substitution: %s//foo/gc
20:21 < SvenG> empty search pattern -> use last search pattern
20:21 <+thp> last search pattern von "/"-suche
20:21 <+thp> search register: /
20:21 < SvenG> what's my last search? insert mode -> c-r /
20:22 < SvenG> likewise for command line: c-r :
20:22 <+thp> bei %s nach dem letzten /: "g" = global (ganzes file), "c" = confirm ("interaktives ersetzen")
20:25 <+thp> command history: q:
20:25 <+thp> von dort kann man yanken oder in ein file schreiben
20:25 <+thp> selection in ein file schreiben: :w filename
20:27 < fantazo> #flausch
20:30 < fantazo> mtr - my toobelt rage
20:31 < fantazo> well, toolbelt. wrong pun 
20:35 <+thp> unter debian heißt das paket "mtr-tiny", "mtr" ist ein gui-tool. das kommando heißt dann aber auch "mtr"
20:37 < SvenG> -rwsr-xr-x 1 root root 52036 2008-11-05 13:39 /usr/bin/mtr
20:38 < fionn`> oder, mtr -t
20:42 <+thp> http://derstandard.at/1319183456363/Fix-Tele2-uebernimmt-Silver-Server
20:45 < fionn`> Was verwendet alle für Filemanagement?
20:46 <+thp> http://ghisler.com/ <- total commander, for windows
20:47 < SvenG> (mtr requires sticky bit.. needs "root")
20:47 < luto> ..which we don't have on uberspace.de
20:48 <+thp> on linux: mc
20:48 < SvenG> pics -> https://www.google.at/search?q=total.commander
20:48 <+thp> http://gqview.sourceforge.net/
20:49 < SvenG> been using gqview in graz in 2004 for vieweing stuff on a projector..
20:49 <+thp> http://projects.gnome.org/eog/
20:49 < SvenG> on my netbook i use "feh" though
20:50 <+thp> this one? http://feh.finalrewind.org/
20:50 < fionn`> geeqie is the replacement for gqview.
20:50 <+thp> http://geeqie.sourceforge.net/
20:50 <+thp> "Geeqie has been forked from gqview project, because it was not possible to contact gqview author and the only maintainer. Geeqie projects goal is to move the development forward and also integrate the existing patches. "
20:52 < fantazo> was ist eigentlich ein nettes shortcut um auf console alle dateien zu löschen in einem verzeichnis, bis auf bestimmte dateien, die auch jetzt keinem Patter entsprechen?
20:52 < fionn`> so, we were talking about Linux *-Commander style filemanager, but with thumbnails or something to organise images.
20:54 < fionn`> another recommendation: htop
20:54 <+thp> for doing non-pattern file management, i use nautilus, with details list mode (sort by size, ...) maybe with ctrl+S ("select files by battern")
20:55 < fionn`> nice feature in emacs file management; edit a list of files like normal text and then it can rename all the files.
20:56 < fantazo> thp, yeah, but that is a gui tool. so probably mc?
20:57 <+thp> fantazo: yeah, i think you can do the pattern stuff in mc too
20:58 <+thp> fantazo: yeah, "mc" then "+" to "add selection via pattern" and "-" "remove selection via pattern"
20:58 <+thp> SvenG's now showing off zsh's globbing with stuff like "only files" or "only regular files"
21:00 <+thp> alt+. in zsh: add something from the history list (not entirely sure what it does ;)
21:02 < fantazo> what do you do if you have to play around with logfiles, which contain some crazy xml and you don't want to write a bunch of sed scripts? I do usally use a perl script with XML::Simple
21:02 < SvenG> names to characters: http://de.wikipedia.org/wiki/Rautenzeichen  
21:02 <+thp> example for the zsh globbing stuff: ls -l *(r.^R) (r = owner readable, . = regular file, ^ = "not", R = world readable)
21:02 < SvenG> teppich -> #
21:03 <+thp> http://fsinfo.noone.org/~abe/Bloedsinn/Teppich.html
21:08 < SvenG> zsh qualifiers
21:08 < SvenG> r 0400 owner-readable    A 0040 group-reAdable    R 0004 world-Readable
21:08 < SvenG> w 0200 owner-writable    I 0020 group-wrItable    W 0002 world-Writable
21:08 < SvenG> x 0100 owner-executable  E 0010 group-exEcutable  X 0001 world-Executable
21:08 <+thp> http://www.fileformat.info/info/unicode/char/1f4a9/index.htm
21:10 < SvenG> ls -l *(....)
21:10 < SvenG> @ - symlinks
21:10 < SvenG> - directories
21:10 < SvenG> / - directories
21:11 < SvenG> alias lsd='ls -adCF *(/)'
21:14 < SvenG> alias lld='ls -adCFl *(/)'
21:14 < SvenG> alias dusch='du -sch'
21:15 <+thp> du -cks
21:15 < SvenG> quack :)
21:15 <+thp> "fat ducks" / what uses so much space: -> du -cks * | sort -n
21:15 < SvenG> aliases in zsh... suffix aliases and global aliases
21:16 < SvenG> alias -g DOC=/home/user/work/foo.doc
21:17 < SvenG> ls -l DOC
21:17 < SvenG> alias -g L="| less"
21:17 < SvenG> command .... -> output
21:17 < SvenG> command .... L
21:18 < SvenG> !! L
21:18 < SvenG> S -> | sort
21:18 < SvenG> G -> | grep
21:19 < SvenG> file 'G' -> \\G
21:19 < SvenG> file 'G' -> \G
21:19 <+thp> aber "ls *"
21:19 <+thp> und "touch \G" vorher
21:20 < SvenG> rm * -> zsh warning!
21:20 < SvenG> mkdir /tmp/foo
21:20 <+thp> setopt rm_star_wait # wait 10 seconds on "rm *" (use tab completion to rm *)
21:20 < SvenG> cd esc-.
21:20 < SvenG> touch foo{23..42}bar
21:21 <+thp> ah, cool, jetzt weiß ich, wozu esc-. gut ist :)
21:23 < SvenG> shell input mode: ctrl-u - gesamten input loeschen
21:23 < SvenG> ctrl-y insert last deletion 
21:25 < SvenG> eins zwei drei vier fuenf sechs sieben acht nuen zehn
21:25 < SvenG> ctrl-a bzw ctrl-e -- anfang bzw ende
21:26 < SvenG> alt-b bzw alt-f -- backward bzw forward by WORD
21:26 < SvenG> --> esc + b  bzw esc + f
21:28 < SvenG> ctrl-b und ctrl-f
21:28 < SvenG> zeichenweise vor und zurueck
21:29 < SvenG> "up key -> ESC [ A
21:30 < SvenG> shell input:  CTRL-V followed by key
21:31 <+thp> also zB CTRL-V <pfeil nach oben> -> zeigt das an, was aus dem pfeil nach oben eigentlich wird
21:33 <+thp> vim -> :help ek
21:34 <+thp> :set noek -> im insert mode gehen die pfeiltasten nicht mehr
21:36 <+thp> CTRL-V + F3 = zB ^[OR
21:43 <+thp> sun keyboard mit zusaetzlichen tasten auf der linken seite
21:46 <+thp> jwz.org
21:46 <+thp> http://www.rose.com/htm/images/sunspecifickeys.jpg
21:51 <+thp> Ctrl+W -> loeschen
21:51 <+thp> Ctrl+Y -> das geloeschte einfuegen
21:52 < luto> Ctrl+W -> das wort links löschen
21:54 <+thp> gibt es sowas wie ctrl+w, aber für "bis zum letzten /", also zB ls /some/random/path/wrong -> loesche "wrong"
21:55 <+thp> killring "holen" -> Ctrl+Y
21:55 < SvenG> CTRL-Y -> isnert last deletion.  ALT-Y switch to previous insertion
21:55 <+thp> killring "durchrotieren" -> Alt+Y (esc, y)
21:55 < SvenG> http://www.guckes.net/bash/bash.readline.txt
21:56 < SvenG> http://www.guckes.net/Setup/bashrc
22:02 <+thp> vi -> D = d$
22:02 <+thp> C = c$
22:03 <+thp> -- pause --
22:05 < SvenG> wir gehen ins centimeter..
22:05 < SvenG> Lenaugasse 11, 1080 Wien (Josefstadt)
--- Day changed Sun May 13 2012
00:13 < luto> wieder @metalab
00:15 < SvenG> re...
00:15 < SvenG> Sun May 13 00:15:54 CEST 2012
00:16 <+thp> http://blog.jonaspasche.de
00:16 < SvenG> weiter geht's!
00:16 < SvenG> fionn`: come back!
00:20 < SvenG> less config... "less -aCMsei" empfehle ich
00:20 < SvenG> .. recommende
00:20 < SvenG> see http://www.guckes.net/less/
00:25 <+thp> git k: k = log --graph --decorate --pretty=oneline --abbrev-commit --all
00:25 < SvenG> \o/
00:26 <+thp> (das in die section [alias] in .gitconfig geben)
00:32 < fionn`> SvenG: sorry, war tätig mit Räumen usw. Wie viel sind noch bei dir?
00:32 < luto> fionn`: wir sind jetzt zu dritt
00:39 < fionn`> less -aCMsei ist gut :) danke
00:44 < SvenG> fionn`: you are welcome! :)
00:45 < SvenG> fionn`: wir sind zu dritt.  mit dir waeren wir zu viert. ;-)
00:53 < fionn``> alias deutsch='dict -h dict.org -d deu-eng'
00:53 < fionn``> alias english='dict -h dict.org -d eng-deu'
00:58 < fionn``> ich gehe
00:58 < fionn``> bis später
01:01  * SvenG is thinking about changing his web pages to git repositories...
01:01 < SvenG> aber machen wir mal weiter mit... mosh
01:25 < SvenG> nochwas zur zsh:
01:25 < SvenG>   zstyle ':completion:*:kill:*' command 'ps xf -u $USER -o pid,%cpu,tty,cputime,cmd'
01:25 < SvenG>   zstyle ':completion:*:kill:*' insert-ids single
01:25 < SvenG>   zstyle ':completion:*:*:kill:*' menu yes select
01:26 < SvenG>   zstyle ':completion:*:kill:*' force-list always
01:37 < SvenG> --> kill <TAB> -> menu! :-)
01:42 <+thp> ctrl+u loescht alles
01:42 <+thp> ctrl+y bringts back
01:55 < SvenG> .zshrc.mine:  zstyle ':completion:*' menu yes=long-list
01:55 < SvenG> .zshrc.mine:  zstyle ':completion:*' menu select=2
03:16 <+thp> mutt: l = "limit messages" (filtern/suchen)
03:16 <+thp> l. = alles
03:16 <+thp> l~h<irgendwas> = <irgendwas> in den headern vorhanden