23 October 2007

Nothing to do . . .

. . . and too many ways to do it. Does this post through Tor (via curl)? We'll see.

15 October 2007

Getting out of my way

Today I got out of my own way by drinking a couple of beers. My productivity (post-alcohol) far outclassed that of earlier in the day. I fretted through the morning. By evening, though, I had got out of my own way. Now I can get something done. (And I dig music.)

14 October 2007

Please, Financial Times

Don't give in! Don't shrink your pages! The New York Times looks ill (in a bad way), and the Wall Street Journal looks more like B-school USA Today (I mean, uh, Investor's Business Daily) every day. Fight! FIGHT!

(As far as I know, the FT is safe and sound and not in danger of getting ugly. To be safe, though: buy a copy today. Even Noam digs it. I resubscribed.)

Labels:

Little helpers

Some of these installed with fink, others with darwinports. Here I present the definitive list of my favorite open-source software for making a Macintosh into an acceptable machine:

  • Oroborus - Window manager for XDarwin; can't do much without one
  • Sylpheed - my mail client of choice
  • Liferea - RSS reader to keep track of news
  • Easytag - For tagging .ogg files that I ripped with OggDrop. Using .ogg files on a Mac is mighty annoying.
  • Epiphany - my favorite web browser. I hear this preference is strange.
  • Emacs-gtk - Aquamacs is okay, I guess, but I prefer GNU.
  • emacs-w3m - Text-mode web-browser from inside of emacs. Extra nerdy.
  • Pybliographer - For managing TeX/LaTeX/BibTeX bibliographies. Not needed if there's a decent Emacs to be found, but easy to use

I also brought my .emacs file and .emac.d folder from my Linux computers; the former worked with only minor changes. As noted below, I needed a .xmodmap file to map the Alt keys on the Mac keyboard to Meta for use in Emacs.

EDIT 15/10/2007 11h00: Also need Bogofilter, without which my work email is hopeless

Labels:

Something like victory

In this file, I would like to create a number of natural line breaks, which I will then make go away by some simple command. I hope to be able to i) compose text with line breaks, then ii) run a script on that text to make it postable through a Blogger API (or something), even though I do not remember what API stands for.

Also: I'd like to preserve double line breaks, as occurs between this fake paragraph and the previous one.

#!/bin/sh # txt2blog.sh - translates auto-filled plain text (possibly with hyperlinks) into a single, blog-ready line with (angle-bracket p angle-bracket) tags and everything basename=$(echo $1 | sed 's/\..*//') echo "Basename of $1 is $basename" echo "Removing /tmp/$basename.txt" rm /tmp/$basename.txt echo "Creating /tmp/$basename.txt" touch /tmp/$basename.txt echo "(angle-bracket p angle-bracket)" >> /tmp/$basename.txt cat $1 >> /tmp/$basename.txt echo "(angle-bracket slash p angle-bracket)" >> /tmp/$basename.txt cat /tmp/$basename.txt | sed 's/^$/(backslash angle-bracket backslash slash p backslash angle-bracket backslash angle-bracket p backslash angle-bracket)/g' | while read line ; do echo -n "$line " ; done | sed 's/(backslash angle-bracket p backslash angle-bracket [backslash angle-bracket backslash slash p backslash angle-bracket backslash angle-bracket p backslash angle-bracket]+/backslash angle-bracket p backslash angle-bracket/g' > $basename.blog echo "Here is the blog-ready file:" echo "" cat $basename.blog

That will do for now.

Labels: ,

I think we've got it.

Yes! Put (add-hook 'tex-mode-hook 'turn-on-auto-fill) in .emacs, so that I can write happily in LaTeX, but leave ugly line breaks out of whatever games I play while posting to blogger. Productive Saturday.

The final straw

It comes down to this: I have abandoned auto-fill-mode on this computer, and I fully expect gblogger-mode to work properly now. It's not such a big deal; I can add auto-fill-mode as a tex-mode-hook. You've won this round-but I'm ready to write now, with no more futzing.

13 October 2007

Ok, that didn't do it

But maybe if I sneak on into to customize-variables and do a little magic there, maybe then I'll have a sufficiently customized xsltproc . . . but I doubt it.

But can I choose my stylesheet?

Well, my guess is that I can't; still, I have now edited g-utils.el to call xsltprog betteratom.css instead of just xsltprog, but I fully expect nothing but a mess.

I am trying to surrender

Since my last effort was a failure, I have been trying (and still failing) to turn off auto-fill-mode in sgml-mode/gblogger-mode, but I am not having much luck. Semi accidentally, I might have found the proper wat to switch stylesheets; let's see if the audience notices the difference.

Now I'm really screwing

around with things I do not understand-I found the css stylesheet that gblogger.el runs each post through; I saved it locally and removed the phrase convertLineBreaks, then I switched the call to atom-view.xsl to hit my new file instead, which (in turn-I hope) will call the local stylesheet. Assuming approximately 74581905 contingencies work the way I want, maybe this post will look better.

Now I'm really screwing

around with things I do not understand-I found the css stylesheet that gblogger.el runs each post through; I saved it locally and removed the phrase convertLineBreaks, then I switched the call to atom-view.xsl to hit my new file instead, which (in turn-I hope) will call the local stylesheet. Assuming approximately 74581905 contingencies work the way I want, maybe this post will look better.

What if

What if (he grumbled), the whole problem is that I've been adding sgml-mode-hooks left and right, when what I really need to do is add a gblogger-mode-hook, since everything that I do to post here is in (surprise) gblogger-mode? I'd be a bit annoyed that it took so long to get it right, but at least there would be some semblance of sanity to it all. And now, I shall add a linkto another sucker's webpage.

What if

What if (he grumbled), the whole problem is that I've been adding sgml-mode-hooks left and right, when what I really need to do is add a gblogger-mode-hook, since everything that I do to post here is in (surprise) gblogger-mode? I'd be a bit annoyed that it took so long to get it right, but at least there would be some semblance of sanity to it all. And now, I shall add a link to another sucker's webpage.

What if

What if (he grumbled), the whole problem is that I've been adding sgml-mode-hooks left and right, when what I really need to do is add a gblogger-mode-hook, since everything that I do to post here is in (surprise) gblogger-mode? I'd be a bit annoyed that it took so long to get it right, but at least there would be some semblance of sanity to it all. And now, I shall add a link to another sucker's webpage.

I guess I just can't stop

At this point, I'll settle for a situation where my text does not suffer a needless linebreak in the middle of a tag. Even thought this advice suggests that my version of Emacs should not commit these unsightly gaffes, it does. So I have inserted the Lisp that they suggest into my .emacs file. Hopeful? No.

Desperation sets in

I appear to be the only person the internet with this problem: gblogger.el adds tons of irritating line breaks when I compose in auto-fill-mode, even though sgml-mode allegedly ignores such nonsense. In this post, I attempt to fix things by activating sgml xml mode in customize-group : sgml, but my hopes are not high.

Desperation sets in

I appear to be the only person the internet with this problem: gblogger.el adds tons of irritating line breaks when I compose in auto-fill-mode, even though sgml-mode allegedly ignores such nonsense. In this post, I attempt to fix things by activating sgml xml mode in customize-group : sgml, but my hopes are not high.

Still struggling

Sure, I could always forget about using auto-fill-mode, and simply type-type away in one gigantic line every post, or I could stop worrying about making the whitespace in these posts look acceptable, but my entire world rests on being able to vomit out my techie/geeky thoughts without having to resort to a web browser, and still have everything look neat. Save me, Emacs-you're my only hope. Memo to self: two hyphens do not an en-dash make. I cribbed some suggestions from this site, but I doubt that this try will look any more acceptable. *sigh*

Still struggling

Sure, I could always forget about using auto-fill-mode, and simply type-type away in one gigantic line every post, or I could stop worrying about making the whitespace in these posts look acceptable, but my entire world rests on being able to vomit out my techie/geeky thoughts without having to resort to a web browser, and still have everything look neat. Save me, Emacs--you're -- --my only hope.

Coming to terms with OS X

I have hated before, but it's beginning to look like OS X is quite totally acceptable--as long as one registers as a "Mac developer" (HA!) and juices up the computer with Linux applications from fink and darwinports.org

There's also a good chance that a bit of EmacsLisp modified from here has finally solved my problems with sgml-mode putting ugly line-breaks into my posts:

(defun local-sgml-mode-hook ()
  (setq indent-tabs-mode nil
 next-line-add-newlines nil
 standard-indent 4
 sgml-indent-data t)
  (auto-fill-mode t))
(add-hook 'sgml-mode-hook
   '(lambda () (local-sgml-mode-hook)))

Also: fooling around in GTK Emacs (Not AquaMacs--*pthbbttt*) was a chore until I learned this neat trick:

put these lines in a file called .xmodmap:

keysym Alt_R = Meta_R
add Mod2 = Meta_R

Now add this line to .profile:

 xmodmap ~/.xmodmap

Brilliant!

UPDATE: No, had to go back and fix this via the web. Still: almost there. Emacs will do what I want, as long as I ask properly

08 October 2007

jpeg problems (mostly) SOLVED

I still cannot view inline images with emacs-w3m, but that is probably just as well. The important problem was that many of my programs--including Liferea and Eye of Gnome, but not including Epiphany or Gimp--could not open jpeg files. I cannot find the forums post that saved me here, but the problem went away after adding tiff to the first line (*/*) of /etc/paludis/use.conf, and re-compiling gtk+. I already had the jpeg USE flag activated, but that had never solved the problem. (I like some Gnome programs, though I run Enlightenment. *pthbbttt*)

is not a symbolic link SOLVED

Another minor issue is finally fixed. A number of *.so.* files--some in /usr/lib, most in /usr/local/lib--got flagged as not a symbolic link during compilation. Well, I finally got around to looking at these files. It turns out that in each case, the not a symbolic link file was identical to another file in the same directory with a slightly longer name--for example, libORBit.so.3 and libORBit.so.3.0.1, or something like that. I moved the former file to a safe place (in case it was hard-linked or something else that might cause trouble if deleted), then created a symlink: sudo ln -s /usr/local/lib/libORBit.so.3.0.1 /usr/local/lib/libORBit.so.3. And now all is beautiful. ALSO: Often during compilation, gcc vomits out a warning that [FILENAME] seems to be moved; as long as this doesn't hurt the compilation (it usually does not), then this is an ignorable warning due to a minor bug in libtool or gcc. Cool.

07 October 2007

docbook-sgml-utils compile error SOLVED

Egad, it took forever to fix this problem. I had seen lots of
jade:../../doc/docbook-utils.sgml:1:55:W: cannot generate system identifier for public text "-//OASIS//DTD DocBook V3.1//EN"
While trying to compile docbook-sgml-utils. The package in question does not seem to be required for much, so I usually just skipped it and updated the rest of my (Ututo/Gentoo) system with paludis. The problem turns out that I was missing part of '=app-text/docbook-sgml-dtd-3.1-r3::gentoo', so a quick paludis -i '=app-text/docbook-sgml-dtd-3.1-r3::gentoo', followed by paludis -i docbook-sgml-utils finally solved my problem. It sure did take forever, though. I found other references to this problem, but no straight-forward solution.