BASIC


Beginner’s All-purpose Symbolic Instruction Code or BASIC was the first computer language I learned back in 1977.


Git Commit Picture


The other day I ran across Victor Martínez’s posting about taking your picture every time you commit. The process is simple enough, you install imagesnap via brew and then add a post-commit hook to any Git repository where you want to record commit pictures.

Victor’s posting also links to a tool you can use to assemble these still images into a video. I’ll have to wait to have a collection of snapshots before experimenting with creating a video.

The only caveat I can see to this technique is that it imposes a dependency on the imagesnap tool. In the case of this site’s repository virtually all of the work is done from a single machine so I don’t need to worry about this dependency too much. However, if I ever move to a new machine I’ll need to instal imagesnap there as well.


Prey Books


I’ve been on a John Sandford Prey book orgy the past couple of weeks. So far I’ve read the first six books of the Lucas Davenport series in order, read the most recent book (#22), and I’m listening to yet another on Audio CD.

{{ “0425205819” | amazon_small_image }} {{ “0425208842” | amazon_small_image }} {{ “0425214435” | amazon_small_image }} {{ “0425224465” | amazon_small_image }} {{ “0425231062” | amazon_small_image }} {{ “0425237745” | amazon_small_image }} {{ “0399157689” | amazon_small_image }} {{ “0425221156” | amazon_small_image }}

I’ve got at least two more audio books from the series and three or four more print books as well. I’ll have to haunt the library stacks for the rest. Once I finish the Prey books I’ll move on to the Kidd books and then maybe the Virgil Flowers ones. I’ve read all of these books before so rereading them is like putting on old favorite clothes.


Octopress Sidebar Categories


After reading Dan Watson’s posting about listing categories in the Octopress sidebar I implemented it on my site.

Where Dan puts the aside in source/_includes/asides I put it in source/_includes/custom/asides, otherwise I followed his setup to the letter.

As a result of seeing my categories listed with a count of their postings I realized that I needed to do some clean up. When assigning multiple categories I tend to separate them with a comma. Octopress parses on spaces between categories so the trailing comma is treated as part of the category name. So posting something in “apple, nerdliness” results in an “apple,” category.

A simple grep command can search through all the postings and return a list of the files that contain one of these comma-added categories:

grep -H -r "categories: apple," _posts/

Some of my mislabeled categories only had one or two postings, one had 49. Not wanting to edit that many postings I used a find command to do the work for me.

find _posts/ -type f | xargs perl -pi -e 's/: apple,/: apple/g'

Since this command alters files you should probably do the work on a branch in case you need to revert following unintended changes.

With my categories cleaned up I now have a set of links in my sidebar allowing readers to investigate my site by topics. Now I just need to plow through the catch-all category (life) and properly tag those entries.


The Manhattan Project


After a week in Manhattan this past March we both wanted to stay longer. This video only adds to that desire.


Bane of Man's Existence


When I was in high school on of my buddies used to say that “glasses were the bane of man’s existence.” Based on my experiences trying to get my lens prescription updated the last couple of weeks I whole-heartedly agree with him.

It’s been three years since I had my eyes examined so I made an appointment with a new eye doctor for early June. My previous eye doctor discovered politics and now works for the state government after closing her vision practice here in town.

The exam was good and as I suspected discovered that my current prescription is no longer quite strong enough. I’ve reached the age where presbyopia is steady diminishing my visual acuity. With my new prescription in hand I set out to get new lenses for my current frames. I like the frames and saw no reason to get new ones. The glasses/frames side of the business where I had my eyes examined said they would need a day to fit the new lenses to my current frames. And their prices were quite a bit higher than the Vision Center at Walmart, so I opted to get the lenses at Walmart.

##Lenses, First Try On a Saturday afternoon I went to the Vision Center at Walmart with a copy of my prescription to order new lenses. The clerk who assisted me had great difficulty getting their computer system to recognize my insurance, and she seemed less than confident in her approach to gather the various measurements necessary. After about 45 minutes she handed me over to the other store clerk (who I’ve worked with successfully in the past). Clerk number two finished the order after another 30 minutes of futzing around. My patience was completely gone by this point so when the customer facing price display showed $170 instead of the stated $80 for the final price I canceled the order and walked out.

Lenses, Second Try

I went back to the eye doctor where I’d had my eyes examined and tried to order new lenses from them. Since they don’t carry my frames the lens would have to be “finished” in the store and fitted to my frames. The clerk said it would take all day - a business day - to accomplish this fitting. I cannot read or operate my computer with my glasses so this would entail a day off from work. I wasn’t happy about that requirement but okay. The total price was $125 - more than 50% higher than Walmart’s price.

After getting home and discussing it with my wife we decided that the premium price was too much and I called and canceled the order.

##Lenses, Third Try I went back to Walmart and ordered the lenses. This time I observed the customer price display more carefully and saw that it only shows two lines at a time, whereas the details of the price, the discount, the insurance allotment, and the total are spread out over many lines. Even though the display says $170 the actual cost is really $80. Lenses ordered.

##Lenses, First Fitting Try A couple of weeks go by and I get a call from Walmart saying my new lenses are in so I go there to get them installed. The first clerk is working that evening and she wasn’t able to setup my glasses properly. In hindsight it appears she managed to reverse the lenses, putting the left in the right-side and the right in the left-side. The are nearly symmetrical over the vertical axis which makes them hard to tell apart. However with them in the wrong sides the frames were visible distorted. When she did get them in right the lines for the bi- and trifocal areas were not parallel to the floor. The were at a 30º angle. I had her put the original lenses back in the frames and agreed to come in the next day to deal with the manager.

##Lenses, Second Fitting Try The manager had no more luck getting the lenses to work and agreed they needed to be remade. She said it would take another week or so. In putting my original lenses back in the glasses she managed to make a 3mm long scratch in the near vision portion of the left lens. Extremely annoying but livable for a couple of weeks.

##Lenses, Third Fitting Try When the second grinding of the new lenses arrived I returned to Walmart and the second clerk installed them for me. The width of the trifocal area was about half of what I’d had before. I had specifically requested that the bi- and trifocal portion of the lens be as wide as possible to match my current lenses. I look at a wide array of computer screens at work and wanted to swivel my head as little as possible. The trifocal area of my lenses is 34mm out of a lens that is 46mm wide.

And the clerk managed to mix up the old and new lenses so that at one point I had the scratched lens in the wrong side of the frames. They could make good use of some little colored stickers to keep track of which lens is which.

After 90 minutes in the store I gave up, requested my original lenses and a refund. To Walmart’s credit they did return my money. But I still don’t have new lenses and I’m reading around a scratch on my dominate eye side.

##Lenses, Fourth Try I am tempted to order new glasses and lenses online. The prices are far lower than from any of the local stores. However, you can’t see and try on the frames ahead of time. The best you can do is look a pictures and measurements. Plus, only one site I’ve checked out of four so far, makes trifocal lenses. I’m not sure I’d be able to specify the wide trifocal area I want. So I am reduced to visiting all the eye glasses stores in town looking for a new frame and new lenses.

The nearest Lens Crafters (where I got many glasses over many years while living in Illinois) is 60 minutes drive away. And I’m not entirely sure they can make trifocals in the store in an hour meaning I’d have to make 2 two-hour round trips.

Maybe I’ll just squint.


Big Wooden Ball Project


What do you do with really big chunks of wood? Custom make a truck sized lathe and turn out big wooden balls.

(via: @jacobian)


Showing Git Commit Counts


For sometime I’ve thought that that using the commit count on a project would make a good version number algorithm. My idea has been to have a file in the project that contains a number. That number is created by a commit hook. Each commit increments the number. I guess this would be more of a “build” number than a true version number. Either way, it would eliminate all the trouble over how to come up with a reliable way to have a MM.mm.pppp version number where MM is the major release, mm is the minor release, and pppp is the patch number.

A quick Google search led me to How to get the git commit count on StackOverflow. As of this posting, answer 14 had two git shortlog commands I liked enough to include in my aliases file.

##Show total number of commits in the current repository This command shows the total number of commits in the current repository for all developers.

git shortlog | grep -E '^[ ]+\w+' | wc -l

##Show number of commits by developer This command is a variation on the first command. It shows each developer’s name and then the number of commits they’ve made to the repository.

git shortlog | grep -E '^[^ ]'

My next project will be to create a git commit hook that works with the first git shortlog command to populate a build count file.


The Fallacy of Choice


The supermarket I shop at most frequently recently moved. They built a larger new store across the parking lot from their old location. The new store is nice but the area of the store I interact with the most, the deli counter, changed for the worse.

In the old store the deli counter always had trays of pre-sliced lunch meat – ham, turkey, roast beef, chicken, et cetera – and pre-sliced cheese – swiss, provolone, colby, and so on. I could walk up to the counter ask for a half pound of honey ham and six slices of baby swiss and in two minutes I had my plastic baggies and was headed toward the checkout.

With the new store the supermarket brought in Boar’s Head meats and changed their entire process. I’m sure the sell behind this was “giving the customer control” or “giving them choice”. It’s awful. What used to take two minutes can now easily take 15 or more. The entire new process is based around asking the customer questions.

I walk up and ask for, say, a half a pound of honey ham. They respond by asking if Boar’s Head is okay.

Boar’s Head is the only meat on display. I have learned that there is another, lesser, brand hidden away that you can get. I suspect the Boar’s Head franchise requires they point out that you are buying Boar’s Head meat and cheese.

They hunt around in the case to find the open Boar’s Head honey ham and take it to a slicer. Pretty soon they return to the counter with a slice of meat on a plastic tissue and ask if the thickness is okay. Usually they hold the meat sample up perpendicular to me so I can’t see the thickness. Some ask me before hand how thick I want it. I always say, “however thick you used to slice it”. This usually doesn’t work as all the deli people are new and have no idea about pre-sliced meat. A chart showing the various thicknesses would be hugely helpful.

Eventually they have a half pound of meat on the scale and package it for me. Then I say I want six slices of swiss cheese, and we start the whole litany of questions over again.

Deli clerk: “Boar’s Head cheese?”
Me: “Yes”

DC: “Which kind of swiss?”
Me: “Baby”

DC: “How thick?”
Me: “3.75 microns”
DC: “?”
Me: “The usual thickness”
DC: Sandwich slices?
Me: Sure

Since there are so many interactions for each transaction it takes longer. If I get to the deli counter and there are two or three people already in line it can easily be 10 or 15 minutes before I get waited on. I used to leave work at 11:30, stop at the deli for lunch supplies and be home by 11:45. Now on days when I need to restock the lunch meat and cheese at home I am rarely home before noon.

The fallacy here is that Boar’s Head, and be extension, Dillon’s, think they are taking better care of me by giving me choice and control over my meat and cheese. They took a working, efficient process, and encumbered it with many needless little steps. I just want to buy some lunch meat, and some sliced cheese so I can make a sandwich for lunch. I don’t want to play 20 questions with the deli help in order to do so.

I’d take my meat and cheese business elsewhere except that all the other deli counters in town operate on the same “Let’s let the customer choose every aspect” model that Dillon’s now has. I suppose I’m in the minority of people who’d rather have a selection of ready-cut lunch meat and cheese so I can just choose and go. I’ll just have to get used to standing in line and playing 20 needless questions about meat and cheese a couple times a week.


Reset Your Password


(via Laughing Squid)