Prev: LewPitcher.ca tops Google Search!
Next: Xorg and Intel Integrated Graphics Chipset: low resolution
From: Michael Black on 27 Nov 2009 11:31 On Fri, 27 Nov 2009, Theodore Heise wrote: > On Fri, 27 Nov 2009 20:04:27 +1100, > Grant <g_r_a_n_t_(a)bugsplatter.id.au> wrote: > >> >> On a new system first things copied from the file server (once I >> get nfs access) are custom .vimrc and .bash* files, the >> ~/.ssh/authorized_keys for root and user, and my kernel build >> scripts. >> >> Then I have vim tamed, and only meet vi in its other roles as >> 'crontab -e' and visudo -- what do the nano, pica people do >> here? > > I admin my own server, but it's essentially single user and I > don't do much that's sophisticated. I've been using Pine for > probably 15 years, so I generally favor pico for most editing. > > When faced with the vi interface that follows 'crontab -e', I > reach for the O'Reilly "Unix in a Nutshell" book, in which I've > put a tab at the chapter on vi. > O'Reilly also has pocket references for both Vi and Emacs. Not tutorials but quick references, which may be enough since most people have experience with editors and simply need to know how to do something on a specific editor. Michael
From: Joost Kremers on 27 Nov 2009 11:33 Sylvain Robitaille wrote: > [...] but if you want to be able to walk up to any Unix/Linux > system, perhaps running from an installation CD, and save the day because > the "clueless user" botched it, you pretty much *need* to be able to > perform at least basic editing with vi. try that on a ubuntu box. -- Joost Kremers joostkremers(a)yahoo.com Selbst in die Unterwelt dringt durch Spalten Licht EN:SiS(9)
From: Sylvain Robitaille on 27 Nov 2009 11:35 On Fri, 27 Nov 2009 04:29:31 +0000, Lew Pitcher wrote: > But ed requires libraries. ... Nothing that isn't likely to be available: : charlotte[syl] ~; cat /etc/slackware-version Slackware 12.1.0 : charlotte[syl] ~; ls -l /bin/ed lrwxrwxrwx 1 root system 11 Nov 2 2008 /bin/ed -> /usr/bin/ed* : charlotte[syl] ~; ls -l /usr/bin/ed -rwxr-xr-x 1 root system 37372 Apr 10 2008 /usr/bin/ed* : charlotte[syl] ~; ldd /usr/bin/ed linux-gate.so.1 => (0xffffe000) libc.so.6 => /lib/libc.so.6 (0xb7e1f000) /lib/ld-linux.so.2 (0xb7f89000) ex, on the other hand ... : charlotte[syl] ~; ldd /usr/bin/ex linux-gate.so.1 => (0xffffe000) libncurses.so.5 => /lib/libncurses.so.5 (0xb7f6a000) libacl.so.1 => /lib/libacl.so.1 (0xb7f63000) libgpm.so.1 => /lib/libgpm.so.1 (0xb7f5e000) libcrypt.so.1 => /lib/libcrypt.so.1 (0xb7f2c000) libutil.so.1 => /lib/libutil.so.1 (0xb7f28000) libc.so.6 => /lib/libc.so.6 (0xb7ddc000) libpthread.so.0 => /lib/libpthread.so.0 (0xb7dc4000) libm.so.6 => /lib/libm.so.6 (0xb7d9e000) libdl.so.2 => /lib/libdl.so.2 (0xb7d9a000) libattr.so.1 => /lib/libattr.so.1 (0xb7d96000) /lib/ld-linux.so.2 (0xb7fc7000) : charlotte[syl] ~; ls -l /usr/bin/ex lrwxrwxrwx 1 root system 3 Nov 3 2008 /usr/bin/ex -> vim* -- ---------------------------------------------------------------------- Sylvain Robitaille syl(a)encs.concordia.ca Systems analyst / AITS Concordia University Faculty of Engineering and Computer Science Montreal, Quebec, Canada ----------------------------------------------------------------------
From: Joost Kremers on 27 Nov 2009 11:45 Sylvain Robitaille wrote: > On Fri, 27 Nov 2009 08:21:21 +0100, Henrik Carlqvist wrote: > >>> Then I saw colleagues doing some things with vim that I'd been wishing >>> I could figure out how to do with Emacs >> >> Even though this thread has since long left its initial purpose I get >> curios. Do you have any quick example of some of those things vi can >> do? > > vim in this particular case, not (ordinary) vi. They're not the same. > > Things like reformatting lines quoted from a netnews article, without > first removing the preceding quote (">") characters, then adding them > back after formatting (highlight the lines in question, then "gq"). fill-paragraph (by default bound to C-q) handles that just fine. it also handles comment syntax in many programming languages. only requirement is that the file is opened in the right mode, e.g. something like post-mode for an email/usenet message. (or whatever gnus uses for composing messages. i've never been able to get used to gnus, mutt serves me just fine.) > Things like being able to edit a vertical block of text. emacs has a set of rectangle commands for that. > Things like > sending selected text to an external command and receiving the output > back into the edit buffer. i now how to do it from elisp, so even if there is no such interactive command it'd be easy to create a function to do that. (though most often, an emacs hacker would probably write some elisp code instead. > There are probably many more, and many might be possible in Emacs, they're *all* possible in emacs, either as existing functions or by hacking up some elisp code. heck, there are even two or three vi/vim emulators for emacs. ;-) -- Joost Kremers joostkremers(a)yahoo.com Selbst in die Unterwelt dringt durch Spalten Licht EN:SiS(9)
From: Joost Kremers on 27 Nov 2009 11:53
Sylvain Robitaille wrote: > On Fri, 27 Nov 2009 04:29:31 +0000, Lew Pitcher wrote: > >> But ed requires libraries. ... > > Nothing that isn't likely to be available: > > : charlotte[syl] ~; cat /etc/slackware-version > Slackware 12.1.0 > : charlotte[syl] ~; ls -l /bin/ed > lrwxrwxrwx 1 root system 11 Nov 2 2008 /bin/ed -> /usr/bin/ed* > : charlotte[syl] ~; ls -l /usr/bin/ed > -rwxr-xr-x 1 root system 37372 Apr 10 2008 /usr/bin/ed* > : charlotte[syl] ~; ldd /usr/bin/ed > linux-gate.so.1 => (0xffffe000) > libc.so.6 => /lib/libc.so.6 (0xb7e1f000) > /lib/ld-linux.so.2 (0xb7f89000) > > ex, on the other hand ... > > : charlotte[syl] ~; ldd /usr/bin/ex > linux-gate.so.1 => (0xffffe000) > libncurses.so.5 => /lib/libncurses.so.5 (0xb7f6a000) > libacl.so.1 => /lib/libacl.so.1 (0xb7f63000) > libgpm.so.1 => /lib/libgpm.so.1 (0xb7f5e000) > libcrypt.so.1 => /lib/libcrypt.so.1 (0xb7f2c000) > libutil.so.1 => /lib/libutil.so.1 (0xb7f28000) > libc.so.6 => /lib/libc.so.6 (0xb7ddc000) > libpthread.so.0 => /lib/libpthread.so.0 (0xb7dc4000) > libm.so.6 => /lib/libm.so.6 (0xb7d9e000) > libdl.so.2 => /lib/libdl.so.2 (0xb7d9a000) > libattr.so.1 => /lib/libattr.so.1 (0xb7d96000) > /lib/ld-linux.so.2 (0xb7fc7000) > : charlotte[syl] ~; ls -l /usr/bin/ex > lrwxrwxrwx 1 root system 3 Nov 3 2008 /usr/bin/ex -> vim* hey, i guess emacs even wins over vim! joost(a)darkstar:~ $ ldd /usr/bin/emacs-23.1-no-x11 linux-gate.so.1 => (0xffffe000) libasound.so.2 => /usr/lib/libasound.so.2 (0xb7eed000) libdbus-1.so.3 => /usr/lib/libdbus-1.so.3 (0xb7eb4000) libgpm.so.1 => /lib/libgpm.so.1 (0xb7eaf000) libncurses.so.5 => /lib/libncurses.so.5 (0xb7e6f000) libm.so.6 => /lib/libm.so.6 (0xb7e49000) libc.so.6 => /lib/libc.so.6 (0xb7ce9000) libdl.so.2 => /lib/libdl.so.2 (0xb7ce4000) libpthread.so.0 => /lib/libpthread.so.0 (0xb7ccc000) librt.so.1 => /lib/librt.so.1 (0xb7cc3000) /lib/ld-linux.so.2 (0xb7fcc000) 12 vs. 11! (don't try this with the X-enabled version of emacs, though... ;-) -- Joost Kremers joostkremers(a)yahoo.com Selbst in die Unterwelt dringt durch Spalten Licht EN:SiS(9) |