Jay McGavren's Journal

2010-03-27

Lenny discovers GarageBand...

GarageBand was one of the reasons I wanted Lenny to have a Mac. So I was pleased that today, all on his own, he fired up Magic GarageBand and then proceeded to manually edit the generated song.

<a href=’http://jay.mcgavren.com/blog/wp-content/uploads/2010/03/magic-garageband-song.mp3’ title=’Lenny’s First GarageBand Song’>Lenny’s First GarageBand Song</a>

His “bridge” starts about 1 minute in. It’s, um, a little eclectic, but it’s a start.

Read more...
2010-03-07

Another Ruby tweet...

Was browsing the new Popular Science archives, which led to an article from 1984, which had a picture of the book Creative Graphics for the BBC Microcomputer, which led me to an archived copy of the book online, which had a dirt-simple program to draw Lissajous curves, which led me to write this tweetable Ruby version. (Phew!)

ruby -rcurses -e"include Curses;i=0;loop{setpos 12*(Math.sin(i)+1),40*(Math.cos(i*0.2)+1);addstr'.';i+=0.01;refresh}" #ruby
****         *******                ********                ******           **
*  *        **     **              **      **              **     *         * **
*  **       *       **            **        **            **       *        *  *
*   *      *         **          *           **          **        **      *   *
*   *      *          *         **             *         *          **     *   *
*    *    *            *        *              **       *            *    *    *
*    *   **             *      *                **     **            **   *    *
*    **  *              **    *                  *     *              *   *    *
*     * **               *   **                  **   *               ** *     *
*     * *                ** **                    *  *                 * *     *
*     * *                 * *                      * *                 **      *
*      **                  **                      **                   *      *
*      *                   **                       *                   *      *
*      **                 * *                      * *                 ***     *
*     * *                **  *                    *   *                * *     *
*     *  *               *   **                  **   *               ** *     *
*    *   *              *     *                  *     *              *  **    *
*    *   **            *       *                *      *             *    *    *
*   **    *            *       *               *        *            *    *    *
*   *     **          **        **            **         *          *      *   *
*   *      *         *           **           *          **         *      *   *
*  *        *       **            **        **            **       *       **  *
** *         *     **              **      **              **     **        * **
 **           ******                 *******                *******         ***

Read more...
2010-03-05

If your code base has .xsl files, and you sometimes confuse them with with the .xls files… You might be a Java dev.

Read more...
2010-02-24

An underinsured taxpayer...

Posted (in vain, I’m sure) to Sen. Jon Kyl’s Facebook wall:

I'm a productive, tax-paying, native-born American with inadequate health insurance for myself and my family. Oh, we tried to purchase private insurance, but no one will underwrite us because my wife had major surgery too recently. We wound up having to settle for a $250-a-month out-of-pocket plan. We pay an additional $300 a month for medications because there's no prescription benefit. I've gone from contractor to salaried status with my employer, so the situation will improve for me. In June, when my benefits start. Until then, I have to wait and worry about my family. Senator Kyl, I ask you, is this an acceptable situation? Is it acceptable for the millions of Americans who won't have a reprieve in a few months? -Jay McGavren, Mesa

Given Kyl’s voting record on this issue I doubt it will even be read. By Senator Kyl, that is. But at least it’ll make the topic a little harder for him to ignore.

I did this as part of MoveOn.org’s virtual march for healthcare reform. Please consider doing the same!

Read more...
2010-02-23

Ruby Tweets!

ruby -e "i=0;loop{puts ' '*(29*(Math.sin(i)/2+1))+'|'*(29*(Math.cos(i)/2+1)); i+=0.1}" #ruby

about 23 hours ago via web

ruby -rtk -e "w=TkCanvas.new(TkRoot.new{title:paint});w.pack.bind('B1-Motion',proc{|x,y|TkcOval.new(w,x,y,x+4,y+4)},'%x %y').mainloop" #ruby

about 3 hours ago via web

Almost got this one short enough to tweet:

ruby -rtk -e"v,w=0,0;a=[1]*9;c=TkCanvas.new;c.pack.bind('Motion',proc{|x,y|a<<TkcLine.new(c,v,w,v=x,w=y,:arrow=>'last');a.shift.delete rescue 1},'%x %y').mainloop"

Ruby Tk

Read more...