Software

Submitted by reeses on Tue, 2005-08-16 21:13.

Software/check-url-update.el

This is an elisp script that will sort-of duplicate the functionality of sites such as http://www.changedetect.com, which suck. Don't use them. Use this script, and when you get sick of it in twenty minutes, write a real program, with real threading, and a real UI, and then give me a copy. Yes, I can hear you OmniWeb types laughing at the rest of us pathetic souls. Tested on XEmacs 21.4.

Addendum: It was suggested to me by one of the employees of the aforementioned service that I was off on a "mindless rant" regarding their suction, and was asked to give evidence. I went to the site to start a list, and was greeted with a MSSQL server error. I don't think I need to continue. :-)

Addendum 2: Thankfully, RSS is appearing everywhere, and external sites such as these will become obsolete very soon.

Other options:

zwebwatch Dashboard Widget

Software/TartMenu (Windows Start Menu on Mac OS X)

http://www.astrogoth.com/~reeses/software/TartMenu.jpg

Prior to the release of QuickSilver, I was annoyed with the lack of a Windows "Start Menu" type facility under Mac OS X. I had converted from Windows, and I was used to having a lot of applications ready to launch. I don't like a cluttered Dock, so putting every single application there wasn't an option. Since I was new to the Mac, I was promiscuously trying just about every application that crossed my path, and I needed a more scalable solution.

I wrote this in Objective C, then realised Boehm GC, while a godsend, was just a little too much overhead for me. Not so much computationally, but in terms of configuration management, since ObjC doesn't have GC out of the box. Besides, Objective C is no longer my biggest development strength.

I had heard many good things about the Java-Cocoa bridge from people, most of whom turn out to be dirty liars. Sure, Java-Cocoa is cool and works better than the equivalent on Windows (is there one?), but the lack of documentation is staggering.

That said, I successfully completed development in Java of a simple Cocoa app that adds a menu item to the system task bar, stores and retrieves user preferences (ok, one user preference), and traverses the Mac filesystem and retrieves properties of bound applications. Once past the documentation hurdle, things work pretty well. I actually think it works better than QuickSilver when trying random things in /Applications, for example, on a new machine, or trying to remember all the silly cutesy apps I downloaded, installed, and forgot about.

Grab the disc image, or if you want to see how this was achieved (or just to fix the myriad problems), grab the source.

Oh, and if you couldn't tell -- I made all the icons myself.

Software/levenshtein.el

This fell out of another project I'm working on. I needed to calculate a string edit distance for sets of strings, and I settled on Levenshtein because I'm lazy, and it was the only algorithm I knew and didn't have to learn. Funny how that works out. This is not at all optimised, and exhibits some of my lisp programming peculiarities, so be forewarned. Tested on XEmacs 21.4.

Software/uniq.el

This is an elisp script that will remove duplicate lines from the selected region. Behavior can either mimic uniq on Unix or remove all duplicate lines from an unsorted file. Tested on both GNU Emacs 20.7.1 and XEmacs 21.4.

Software/Specials Grabber, Ruby version

This is a Ruby version of the Python script below. I used Ned Konz's ruby-htmltools for this.

Software/Specials Grabber

This is a very simple and very, very sloppy Python script to grab and (sort of) parse specials from Buy.com and compgeeks, and display them in a single web page.

It's slop, but it took about ten minutes to write. Feel free to clean it up. ;> The right way to do this is by converting the html into xml, and applying an xslt to the resulting document. Actually, now that sites such as techbargains and fatwallet exist, the right way to do this is not to.

As a side note: is it really possible that Python doesn't ship with a stack in the standard library???

Software/To Do List Plugin

This (src) is another stab at a JEdit plugin. It's a simple to do list manager that plugs into the dockable frame. I haven't tested it much, and it was a one-evening effort to practice my Java Swing skills, but I'll probably add a few more necessary items to it. Right now, persistence is a kluge, and the UI is marginal.

To install, drop the jarfile into your /.jedit/jars directory.

Software/Dictionary Lookup

This (.zip) is a small html script and Windows Registry file that adds a right-click menu to text selections in IE. When selected, it opens a window with the dictionary.com entry for the selected text.
It's incredibly simple, and you're encouraged to follow the model for new right-click services. It uses the MenuExt? entry in the registry, and the external.menuArguments IE scripting object.
See this and this for more information.

Software/JTeXPlugin

This (src) is a plugin for the JEdit IDE. It's pretty primitive right now, but it allows you to run LaTeX on the selected buffer. You can also view the output from "latex -version", it's so advanced. It's double plus unconfigurable at present. I wrote this in a couple of hours, which is about ninety minutes longer than it should have taken, but the JEdit Plugin documentation stinks. I had to read the JEdit source, and the source of several other plugins, to figure out exactly what properties were named, how actions were invoked, etc. Email me if you're starting down the same road and need some help.

I haven't tested this anywhere other than Win2k with MikTeX.

I just discovered Commando, in the Console plugin. I could have saved myself a few hours by writing a tiny command descriptor instead.

Software/factorial.cpp

This is a quick hack that was the result of a discussion on interview questions. A friend's coworker asked an interview candidate,"Can you write a recursive factorial function?" My friend and I joked about hazing an interviewer or an interviewee in the situation -- what language, what's the maximum value to expect, should we eliminate tail calls, etc. So, taking something that would be easy in lisp ((defun fact (x) (cond ((= x 0) 1) (t (* x (fact (1- x)))))), untested ), I wrote a quick and lazy char*-based solution in C. All I did was implement simplistic decrement, addition, and multiplication mechanisms for strings of numbers. It was interesting to see four lines of lisp turn into 140 lines of sloppy C.
As a caveat, this runs beautifully on MSVC/Win2k, but acts strangely on Linux. It also leaks memory like a sieve, because I don't free() anything. I do not think the two problems are coincidental. Tant pis.

Software/TeraTerm Pro IE Launch Modification

I found myself doing a lot of "select, copy, open IE, paste into address bar" with TeraTerm Pro, so I added a menu item to take the current selection, and open IE with the selected text as the target. I didn't add anything fancy like url-recognition a` la gnometerm, eterm, etc, and it does absolutely no data validation. Anyway, download the diff here. It works fine with the fantastic TTSSH, and builds semi-cleanly in MSVC 6.0, with a few warnings at /W4. I don't know if it is kosher to distribute a binary, so if you are the author, let me know if I need to yank it.

Software/MiniMTA

MiniMTA (tar) is a very small Java class that will relay messages via SMTP. This was developed for use on my SGI/IRIX box, because gcc doesn't play well with native libraries. It works for me, but it might not for you.

Software/imgsrc

imgsrc (source) is a tiny program that takes a filename as input, and stuffs an <img src="foo" width="bar" height="baz"> tag string into the Windows Clipboard. It will pull the width and height out of most gif, pcx, png, and jpeg files. The bmp format was too gross to do in one sitting, so I left it out. You shouldn't be putting bmp files on your website, anyway.

In case you were wondering, pcx was horrendously easy, which is why I bothered to put it in.

Grab the cheesy Unix port that dumps the string to stdout instead of the clipboard.

It's very similar to a small component of a perl application called imgsizer, but it doesn't have dependencies on any external applications. (apart from a std c compiler)

Software/systrayal

systrayal takes a command string as an argument, and hides in the systray. When you left-click on the icon in the tray, or right-click and choose the appropriate menu item, it executes the command. I use it to start my browser up and go to the sites I visit most, with "systrayal start http://www.foo.com".

Software/txt2java.py

txt2java.py is my first Python script, which was written mainly to stick my toe in the water. The side benefit of this exercise is a tiny proglet that takes text from stdin, and outputs a Java fragment, which, when added to an existing Java method, will build a java.lang.String object containing the contents of the text.

This will probably end up being used as a template for myriad text filters.

Software/commentator.py

commentator.py will take a block of text and convert it into a somewhat valid comment block for various languages. It's really primitive, and not very Pythonish, but it meets my needs for slapping the same boilerplate into source files in multiple languages. I wrote this because I was up late at night, bored, visiting my girlfriend's grandmother in New Jersey.

Try python commentator.py -h for options.

Post new comment

Captcha Image: you will need to recognize the text in it.
Please type in the letters/numbers that are shown in the image above.