Have you ever seen a stream of data coming from a network, and it has some European accented characters in an encoding you don't recognize? Sometimes bad coding practices or assumptions about encoding when pasting into documents make the encoding on the file not match all or part of the encoding of a document. This is a quick way to find out what encoding(s) match.
It's not fully automated, it still requires your eyes. But it can make a difference when you're writing parsing code and you don't know what to do with some edge cases. Maybe some code like this coupled with a spell checker inside the loop would give you some sense of automation.
Read the rest of this entry »
October 2nd, 2009 in
Mac |
1 Comment
Put this somewhere in your ~/bin:
?????? ????? ???? watch 'echo "show processlist" | mysql -u whateveruser --password=mypassword | grep -v "show processlist" '
Now run it and you will have a poor man's monitor, kind of like top but for MySQL. That coupled with screen (or multiple terminals) may give you some quick and easy piece of mind ?????? ????? ????
This should give you *a lot* of monitoring automation ideas. It should be easy to put together a shell script that puts it all in a little "important things panel" to use watch on. Sometimes that's all you need. ??????? ?????? ????? 40 ???
?????? ????? ???? ??????? ?????
May 14th, 2009 in
SQL |
No Comments
Ubuntu Geek provides a great little guide on speeding up Firefox. A lot of the about:config settings he proposes changing are already fairly optimal on a Mac, but disabling IPv6 seemed to make the most difference on my case.
[From Speed Up Firefox web browser | Ubuntu Geek]
Check it out and have fun
????? ????????????
As a software writer, I download a lot of sample software. In the software world, most people are good about working with their community, and the way you conduct yourself in business matters a lot. This is why I was so amazed to receive this today.
Read the rest of this entry »
This script logs into your JIRA and creates OmniFocus tasks for each of the JIRA items that are assigned to you, so they sync to your Omnifocus for iPhone, you only have to keep track of one inbox, etc. It only takes a tiny bit of setup.
Read the rest of this entry »
March 4th, 2009 in
Ruby | tags:
gtd,
Mac,
Ruby |
6 Comments
Vincent Hellot over at FuzzyCom teaches how to use dtrace to trace javascript problems on a Mac (using a specially compiled Firefox binary for OSX). He hints at being able to do it with Ruby on Rails as well. Haven't tried this, but can't wait to do so.
???????? ??????? ?????? ??????? ??????
????? ???????? ?????????
This post aims at introducing the DTrace debugging tool in the scope of a javascript application. It won’t get too deep in the wide field of DTrace functions but I hope it will give you an overview of how DTrace can help to solve performance and debugging issues in your javascript applications
[From FuzzyCom :: Using DTrace for javascript debug on OS X in firefox]
February 10th, 2009 in
Mac | tags:
Mac |
No Comments
Found this on my "fortune" program today:
"Computer literacy is a contact with the activity of computing deep enough to make the computational equivalent of reading and writing fluent and enjoyable. As in all the arts, a romance with the material must be well under way. If we value the lifelong learning of arts and letters as a springboard for personal and societal growth, should any less effort be spent to make computing a part of our lives?"
-- Alan Kay, "Computer Software", Scientific American, September 1984
Fantastic!
??????????? ????????? ????????
January 28th, 2009 in
Uncategorized |
1 Comment
Yesterday a coworker pointed me to ruby's appscript. I have found it nothing short of amazing.
I love my Mac, and many of us like the idea of automating our software, until we try to use AppleScript to do it. To say that Applescript is professional developer unfriendly is an understatement. I like ruby but to make ruby and applescript talk requires sending strings to osascript in just the right way and getting the output from osascript back. Not a lot of fun at all.
Enter appscript. Appscript is a ruby library that interfaces with applescript seamlessly.
Read the rest of this entry »
January 23rd, 2009 in
Mac,
Ruby | tags:
Mac,
Ruby |
2 Comments
If you're a developer and use Terminal.app, don't set "unlimited" on the buffer size. After a day of using it heavily to review logs and whatnot your computer will be *really* slow. It's Terminal.app keeping in RAM what you did yesterday. Stupid and Obvious, but still figured I'd write it down.
????????? ?????????? ????? ????? ????? ????? ???????
January 14th, 2009 in
Mac | tags:
Mac |
4 Comments
I'm a total troublemaker. For my first Core Data app I decided to do something nontrivial (multiple windows referring to a single document). Of course nontrivial means that the Interface Builder can only help me so far. So now I'm stuck trying to get things to work out right. Luckily Patrick Geiller has put together a good explanation of how you can share multiple nibs across an application. Now all I have to do is apply this same data sharing technique to the NSDocument instead.
????? ?????? ????? ????? ?????? 50 ??????
When using multiple NIBs, we need a common object that will share data among them. That object will hold bindings, outlets, target/action shared across NIBs.
[From Bindings, Outlets, Target+Action across multiple NIBs
????? ???? ???????? ????????
]
December 15th, 2008 in
Mac | tags:
Mac,
Objective C |
1 Comment