A place for John to record his techy notes, both to refer back to when needed, and as a help for others...
Monday, September 20, 2004
Thursday, September 16, 2004
Vim bits...
Today I learned that if I want to run the current line as a command and get
the output, all I have to do is:
<Esc>yy!!<Ctrl-R>"<BS><Enter>
:-) happy now!?
Careful if you've got a % in the line...
Vim documentation: cmdline
I needed \% for the %20 in the URL I was passing out.
The <BackSpace> was because it put a ^M on the end of the line.
I could have just gone 0y$ instead of yy
I just KNOW I'm going to use this one a lot!!!
So you know, the secret engrdient here is ^R which puts the content of the
un-named register on the command line.
the other (unrelated) thing that I looked up and clarified was the :a (short for *:append*) command (and discovered that there's also :i (short for *:insert*) which can be read about with :he :a and :he :i :o) I discovered :a quite by accident a long time ago and use it when I want to paste in text and don't want it to be auto-indented (if it has tabs or indents in it - e.g. when pasting code)
the output, all I have to do is:
<Esc>yy!!<Ctrl-R>"<BS><Enter>
:-) happy now!?
Careful if you've got a % in the line...
Vim documentation: cmdline
I needed \% for the %20 in the URL I was passing out.
The <BackSpace> was because it put a ^M on the end of the line.
I could have just gone 0y$ instead of yy
I just KNOW I'm going to use this one a lot!!!
So you know, the secret engrdient here is ^R which puts the content of the
un-named register on the command line.
the other (unrelated) thing that I looked up and clarified was the :a (short for *:append*) command (and discovered that there's also :i (short for *:insert*) which can be read about with :he :a and :he :i :o) I discovered :a quite by accident a long time ago and use it when I want to paste in text and don't want it to be auto-indented (if it has tabs or indents in it - e.g. when pasting code)
Tuesday, September 07, 2004
Island sizes...
Isle of Man is 53km (33 miles) long, 20km (13 miles) wide, land area 572 sq km (227 sq miles)
Great Barrier Island is 40km (25 miles) long, 16km (10 miles) wide, land area 285 sq kilometres (110 sq miles)
Chatham Island 61 km (38 miles) long, 40 km (25 miles) wide, 963 square km (372 sq miles)
Stewart Island is 70 km long (45 miles) long, 40 km (25 miles) wide, land area 1,746 square km (674 sq miles)
Jersey is 16km (10 miles) across, 8 km (5 miles) from north to south and has an area of 115 square km (44 sq miles)
(Don't quote me on the Chathams length and width - they're from the 1911 encyclopedia which is full of inaccuracies.)
Great Barrier Island is 40km (25 miles) long, 16km (10 miles) wide, land area 285 sq kilometres (110 sq miles)
Chatham Island 61 km (38 miles) long, 40 km (25 miles) wide, 963 square km (372 sq miles)
Stewart Island is 70 km long (45 miles) long, 40 km (25 miles) wide, land area 1,746 square km (674 sq miles)
Jersey is 16km (10 miles) across, 8 km (5 miles) from north to south and has an area of 115 square km (44 sq miles)
(Don't quote me on the Chathams length and width - they're from the 1911 encyclopedia which is full of inaccuracies.)
Sunday, September 05, 2004
USB Mouse with 2.6 Kernel
To get my USB mouse working with the 2.6 kernel (in Debian Sarge with 2.6.7)
I had to add these modules to /etc/modules:
usbhid
uhci_hcd
mousedev
I didn't need usbcore because it loaded itself.
I found that these also work for the 2.4.27 kernel, and I don't need the usbmouse module.
I had to add these modules to /etc/modules:
usbhid
uhci_hcd
mousedev
I didn't need usbcore because it loaded itself.
I found that these also work for the 2.4.27 kernel, and I don't need the usbmouse module.
Subscribe to:
Posts (Atom)