Showing posts with label tech tips. Show all posts
Showing posts with label tech tips. Show all posts

Tuesday, December 15, 2009

Today in Geek, 12/15/2009

I have been terrible about blogging. Wow. Let's just put this shameful period behind us, shall we?

To do so, I'm going to start a new tradition by revising an old tradition. The title pretty much explains it. Here are the geekly stories that piqued my interest today:

Politics
D.C. Council Approves Gay Marriage. There's a good chance D.C.'s overlords in the US Congress will overturn this law, but the Washington, D.C., City Council passed a measure today to legalize same-sex marriage in the District. Strong work, D.C.

Medicine
Locked-in man controls speech synthesizer with thought. Locked-in syndrome is the condition where a person is completely paralyzed (unable to move any muscle and thus unable to communicate), but completely aware of their surroundings. I know I'd heard of it before they featured it on House, so I think at least two medical dramas showed how terrifying it would be. That might change soon, now that a locked-in man has controlled a speech synthesizer with thought. That's just unbelievably awesome. Such technology will also come in handy in the construction of my mecha, so that's good news, too.

Mad Science
Swiss Geologist On Trial For Causing Earthquakes. An experimental geothermal energy project triggered earthquakes in Switzerland, so now the guy in charge is being tried. Sure, they're spinning it more as an industrial responsibility kind of thing, but it sounds to me like they may have caught a real mad scientist (it was an experiment to see if this process would work for energy production, so he wasn't just a mad engineer).

Tech Tips
Create Instant Navigation Shortcuts from Android's Home Screen. Someone at Lifehacker noticed that we can create one-touch shortcuts for turn-by-turn navigation on our Android phones now. For example, I have a button on my home screen to navigate from wherever I am to my house. Neat.

Entertainment
The Lord of the Rings Trilogy Hits Blu-Ray April 6. Dammmmmit. I don't think I'll be able to hold out until they put out the extended editions months later (my guess: just before The Hobbit comes out in December 2011). How many times are they going to convince me to buy these movies???

That's it for today. Did I miss anything? Let me know in the comments.

Thursday, September 10, 2009

Google Reader Send To Remember the Milk Lists

This isn't perfect yet, and that makes me angry. But it's getting there, and I'm hoping someone can help me finalize it in the comments.

What this trick will do: Allow you to send articles to specific Remember the Milk lists (I set up a Mad Science Monday list, and another one to add things to my Personal to-do on RTM, and one for food-related articles, and another for work-related articles) from Google Reader.

What you'll need:
Do you have all of that set up? Ok, open up your Twitlet bookmarklet (right click and Edit it, most likely, depending on your browser), and copy that mass of confusion in the URL field. All you really want out of that is the part after ?a= and before &t=, which will be a jumbled mass of letters and numbers (that's your personal code for Twitlet).

Now go to Reader, and click Settings, and then Send To. Down at the bottom, click Create a custom link. Name it something to remember it by (for example, I used MSM and To-Do for mine). For the URL field, you want this:
http://www.twitlet.com/updates/?a=YOURCODE&t=d%20rtm%20${title}%20${short-url}%20%23LISTNAME
Obviously, swap in your code for YOURCODE and the name of your list for LISTNAME. If you have spaces in the name of your list, replace them with %20's.

For the Icon URL, enter this: http://www.rememberthemilk.com/favicon.ico (that'll put a RTM icon on it).

Now save it. Make more as necessary. Enjoy.

Oh, you'll have to tell your browser to allow popups from Reader (you need to do that for any Send To), and (here's the annoying part) the window that pops up is pointless; you can close it again after it loads. It just needs to load for this to work. I guess I might be able to kill it with a user script, but that's a bit overboard. Does anyone have any suggestions?

Friday, August 14, 2009

Heavyweight Dropboxing

I love Dropbox. It's a simple tool that lets you synchronize files between multiple computers (such as a laptop and a desktop, or a work computer and a home computer), and it even lets you share files with friends or coworkers who also have it installed. It syncs files in the background, so you don't have to wait to open them once you actually need them; once they're synced, they're stored on that computer's hard drive (although they're also available through a handy web interface). Useful stuff all around.

But, back in February, Lifehacker had an article explaining how to sync folders outside of your Dropbox folder. I could tell that was potentially useful, but it took me a while to figure out the powerful way to use this: syncing things like settings folders for applications.

The Lifehacker article has details for other operating systems, so I'll only be covering the Windows Vista versions of the trick here (see their article if you need to figure out how to apply it to your non-Vista computer).

Syncing User Scripts Between Google Chrome Installations

I'm a big fan of Google Chrome, even moreso now that they support user scripts. User scripts are javascript tricks to add functionality to web pages. For example, I have a "Preview" button on each article in Google Reader (thanks to this script). I didn't want to have to remember to set new user scripts up both on my desktop and my laptop, though, so I made both of my user scripts folders point at a folder in Dropbox, like this:

mklink /D "C:\Users\USERNAME\Documents\My Dropbox\User Scripts" "C:\Users\USERNAME\AppData\Local\Google\Chrome\User Data\Default\User Scripts"

Note: Once you do this, the synced folder will already be there when you get to your other machine. You may have to turn off Dropbox, rename that folder, then do this, and then copy everything over from the renamed folder (if you leave Dropbox on while you do that, it might break your link on your other computer, and then you'll have to do the whole process again, etc).

Syncing Digsby Chat Logs

While I love that Digsby stores my setup online (so it's all ready to go on whatever computer I use), it sometimes annoys me that the chat histories (other than Google Chat, which saves its own history) aren't always available; I have to remember which machine I was on when I talked to someone about something. Well, I used to. Not anymore.

mklink /D "C:\Users\USERNAME\Documents\My Dropbox\Digsby Logs" "C:\Users\USERNAME\Documents\Digsby Logs"

As with the Chrome syncing, you'll want to be careful about this, so you don't accidentally delete your other relative link. Also, you have to decide which set of logs you want to keep (or merge them manually, but that could be painful). I'm keeping my work logs, and copying them into the home folder (replacing duplicates).

I'm digging for more options like these. Let me know in the comments if you have other useful ideas.

Wednesday, July 29, 2009

Multi-Parameter Firefox Keywords and Chrome Search Engines

By far, my most popular post is my guide on Firefox Keywords and Chrome Search Engines. I recommend reading that one to get caught up if you don't know what Firefox Keywords and/or Chrome Search Engines are.

Shortly after I wrote that, I found this post on Lifehacker explaining how to combine bookmarklets and keywords for some very clever and useful tricks, but it didn't work on Chrome as written, and I never got around to figuring it out. Tonight I finally took the time to figure it out.

The problem (besides the Lifehacker example being overly complicated) is that Chrome doesn't like {}'s in keywords. Those aren't really necessary unless your keywords are very complicated, though, so I got it to work. This is the code we'll be working with:

javascript:
var s='%s';
url='YOUR URL, WITH %s's FOR EACH TERM';
query='';
urlchunks=url.split('%s');
schunks=s.split(';');
for(i=0; i<schunks.length; i++)query+=urlchunks[i]+schunks[i];
location.replace(query);

As it says in the code, all you need to do is insert the url you want to use, with the usual %s's anywhere you want to insert a search term. You then set it up like any other keyword or search engine (see the other post for how to do that; note: you can just copy/paste the multi-line code into Chrome or Firefox, they don't require that you condense it down to one line first). To use it, just separate your search terms with ;'s.

This fairly simple code can let you do some very cool things. Here's an example for mapping between any two points in Google Maps:

javascript:
var s='%s';
url='http://maps.google.com/maps?saddr=%s&daddr=%s';
query='';
urlchunks=url.split('%s');
schunks=s.split(';');
for(i=0; i<schunks.length; i++)query+=urlchunks[i]+schunks[i];
location.replace(query);

I set this up as a Chrome search engine with keyword "mapp" (although something like "directions" might be easier to remember). If I type "mapp NYC; DC", I get a google map between New York City and Washington, DC.

A warning: if you include a space after the ; like I did in that example, you technically get a space before your second search term. I could probably over-complicate the code and clean that out, but it works fine for Google, and I can learn to avoid it once I set up ones that don't tolerate it. Oh, and if you include more ;'s than the keyword has %s's, the extra stuff will just be tacked onto the end (for example, "mapp NYC;DC;Other" tries to generate a map between "NYC" and "DC Other"

If you use this, please let me know in the comments if you come up with any clever ones. Remember: this works for any url that you want to insert something into, not just searches, so there are definitely some interesting possibilities out there waiting to be discovered.

Wednesday, July 08, 2009

Subscribing to Specific Labels

I'm sure most of you reading this like to read everything I write, regardless of whether it's about politics, mad science, or food. However, some of you may only want to keep up on one aspect of my blogging. If so, here's how to subscribe to a specific label (aka tag) from my blog.
  1. Figure out which label you want (they're over there on the right), and note it. Make sure you have the spelling right. Click the label to see if there are any special characters you need (for example, "mad science" is actually "mad%20science", because the space has to be encoded as %20 so browsers can understand it; %20 is currently the only special encoding you need for any of my labels, but that could theoretically change in the future).
  2. Add that label to the end of this url: http://jonthegeek.blogspot.com/feeds/posts/default/-/ (for example, http://jonthegeek.blogspot.com/feeds/posts/default/-/mad%20science).
  3. Add that url to your favorite RSS reader
That's all it takes. Enjoy!

Note: The same trick works for any blog here on blogger, just replace "jonthegeek" with the url of the blog you want.

Wednesday, June 10, 2009

Obsessing Over My Music Library

Update: See below for edits regarding iWatchSyncer.

Most of my music listening occurs on my laptop at work, but most of my music library is on my desktop computer at home. A friend introduced me to Dropbox, which has allowed me to mostly easily transfer music between home and work, but I still had a problem. Often, I'd randomly think of a song that I hadn't heard in a while, and, inevitably, it wouldn't be one of the ones I had transferred to my laptop. Sometimes I'd remember to remedy that when I got home, but I knew I could do better. Finally, as of this past weekend, I can.

I'm still working out some kinks, but I can now:
  • Access any song in my library from anywhere (as long as I have internet access, which I do as long as I have my phone and/or a laptop).
  • Access my library through an easy-to-remember URL.
  • Download any track in my library to whatever computer I'm on (this one doesn't seem to work on my phone yet, unfortunately).
  • Play any track from my library, as long as I have the Flash player.
  • Add newly acquired music to my library from any computer.
How did I accomplish this wonder of modern technology? Read on. Note: These are instructions for Windows. If you want to do this on Linux, you can probably do it much more easily. If you want to do this on Mac, there's probably a way to do it, but I don't know what that is.

1. Install iTunes.

I would have preferred to do this in a player-neutral manner (particularly because iTunes sucks for the "add to my library" step), but the share-the-library-online program uses your iTunes library, so c'est la vie. The more organized you can get your library in iTunes, the better. Mine is currently terrible, but Lifehacker has at least one post every week about a new tool that will make tagging and organizing your iTunes library easy. So far they haven't, but I keep hoping.

2. Install pulpTunes.

This is the meat of the process, the thing that will share your library. Two things: If you have a router, you'll have to open up port 15000 for it (specifically, you'll have to direct traffic on that port to the machine that's running it). Instructions for how to do that are included, and vary by router. You should also set up a password for it (both an admin and a normal user, if you want to give access to anyone else); that isn't enabled by default. On Vista, it may also be necessary to run this as admin (I'm not sure).

3. Set up Dynamic DNS.

This step isn't strictly necessary (especially if you have a static IP address or don't reboot your router very often), but I wanted to make this easy and stable, so I set it up. Be sure to use the auto-updater app from DynaDNS, so your alias will update if, for example, there's a power outage wherever you're hosting your library.

4. Get Dropbox.

Again, this isn't strictly necessary, but Dropbox is sweet, and adding tracks to your library from anywhere is nice. Set this up on any machine that you use often, but you can also access it online (so anything you put in your Dropbox is already accessible from anywhere, but I'm assuming you want to have more than 2GB of music available).

5. Install iWatchSyncer (for now).

I am not in love with this solution yet, but it's the best I've found (Update: It does everything I need it to do; I think the LifeHacker review sold it short, or perhaps I just misunderstood what it did). I wish iTunes would just do this automatically like every other music player, but oh well. Set this up to monitor your Music folder in Dropbox. In theory, Whenever you dump something into that folder (from anywhere), it'll get added to your iTunes library.

I say "in theory" because, although this worked great when I first tested it, it doesn't seem to be updating as quickly as I'd like. I need to look into it more, and will post an update when I have one. It's possible I just have to reload my pulpTunes instance when I get home to push the update; I'm not sure yet. More info on that when I have it.

The drawback of iWatchSyncer (versus the other, similar program Lifehacker recommended) is that it can't recurse subdirectories; you have to dump anything you want synched "flat" into your Music folder (ie, as the file only, without any folders). The problem with the other one Lifehacker recommended is that they wanted me to give them money in order to actually use it, and I didn't want to actually pay for any of this.

6. Set up all of that stuff to load when Windows loads.

Some of it will do it automatically, some won't. Make sure it all does, mostly in case your power goes out.

That's it! Trust me, it's easy. Let me know if you have any tweaks to make it work even better.

Tuesday, February 10, 2009

Firefox Keywords and Chrome Search Engines

In my last blog, I mentioned Chrome search engines, and how you can use them to make your address bar smarter. I had never noticed these in Firefox, but they're also there. Chrome makes them a bit more obvious (with the "Press TAB to search..." thingies), and adds them automatically for pages that you search on that are formatted in a way that Chrome can recognize, but they're there for all of us (well, except weirdos using IE or Safari; they might be there, too, but who would know?). These things are very useful if you have to poke around within a site a lot with just slightly changed URLs (I need to do this several times a day, loading different itemIDs in an author view or student preview), but they're also useful if all you want to do is search. Here's how they work.

Firefox:
  1. Create a new bookmark. It can be any page; we're going to edit it to make it what we want. Starting from Google for a Google-based keyword wouldn't be a bad idea, though, to get the favicon right.
  2. Click Bookmarks, then right click the new bookmark and choose Properties (or whatever the equivalent is on Mac).
  3. Change the Name to something to remember it by in case you need to edit it in the future, such as "Google Map Search" (or whichever one you might be setting up).
  4. Change the Location to the url you're going to search, with %s for the word or phrase you want to search on. To put that in concrete language and hopefully make it more comprehensible, let's do one of my favorites, "map" (for looking something up in Google Maps). We'll do a cooler version of this in a sec, but this is an easier place to start. For this one, your Location is http://maps.google.com/maps?f=q&hl=en&q=%s
  5. Most importantly, change the Keyword to something short to type, "map" in this case.
  6. Save changes.
Chrome:
  1. Right click the address bar, and choose "Edit search engines."
  2. Click "Add"
  3. The name, keyword, and url are the same as Firefox. The only difference is that Chrome will give you the "Press TAB" clue to let you know that you have a keyword setup with that name.
To use these things, type your keyword in the address bar, followed by your search (for example, "map 123 Fake Street, 78754". The page will load, with your search.

Note that these don't have to use search engines; any time you can fill in a phrase in a url to go to a page you're looking for, it works. It's hard to give you examples of that, since I can't show you the ones I use at work... but, well, for example, this one will load an xkcd comic by ID number:
  • keyword: xkcd
  • location: http://xkcd.com/%s
Typing "xkcd 526" in your address bar would then load one of my favorite xkcds, which you should keep around for reference.

Here are some others (note: in Chrome, I highly recommend just going to most of these pages and searching to get them into your list, and then editing the keywords; the url they grab has some extra trickiness that's neat, but I'm not going to sort out all of how those extra bits work):
  • YouTube: you, http://youtube.com/results?search_type=search_videos&search_query=%s&search_sort=relevance
  • Amazon: am, http://www.amazon.com/exec/obidos/external-search/?field-keywords=%s&mode=blended
  • IMDB: imdb, http://www.imdb.com/find?q=%s
  • Merriam-Webster: mw, http://www.merriam-webster.com/dictionary/%s
  • Allrecipes.com: cook, http://allrecipes.com/search/recipes.aspx?withterm=%s
  • Images.google.com: i, http://images.google.com/images?gbv=2&hl=en&q=%s&btnG=Search+Images
  • Maps.google.com: map, http://maps.google.com/maps?f=q&hl=en&q=%s
And this brings me to my favorite: mapto. This one is slightly trickier. The easiest thing to do is probably to search for your starting address (I have this set as my work address for my work lappy, and my home address for my home desktop) using "map YourAddress," and then copy that string into this.

Here's an example, with 1600 Pennsylvania Ave NW, Washington, District of Columbia 20006 (the White House) as our starting address:
  • Keyword: mapto
  • Location: http://maps.google.com/maps?f=d&saddr=1600+Pennsylvania+Ave+NW,+Washington,+District+of+Columbia+20006&daddr=%s&hl=en
Notice the +'s; if you're careful, you could just change that to your address. You can actually shorten that a bit; for example, this would also work:
  • Location: http://maps.google.com/maps?f=d&saddr=1600+Pennsylvania+Ave,+20006&daddr=%s&hl=en
Once you have that set up, you can type "mapto DestinationAddress" (for example, "mapto 1600 Pennsylvania Ave, 20006"), and a map from your starting address to that destination address will load.

Let me know in the comments if you have any other creative uses of keywords.

ETA: Be sure to check out the follow-up to this post, where I discover way cooler tricks.