Tuesday, July 21, 2009

Learning Unix

I was recently given the task of learning Unix on my Mac. Recently, in this case means last week. I make no claims of being a Unix expert, but I am making some good headway. So, I thought I'd compile a post that tells others in a similar situation what resources I found helpful. If you have other suggestions, please add them in the comments.

Read:

Hayne, Cameron. "Unix FAQ (for OS X)", Hayne of Tintagel.

It's fairly long, but it provides a great overview of what you're trying to learn. There is plenty of opportunity to practice while reading through the various sections.

As you read, keep the following reference chart handy:

"An A-Z Index of the Apple OS X command line". This basically tells you what all the commands do and shows you the syntax required to use them.

Next, try the following questions, compiled by Bill Turkel to keep me occupied while he did more important work:

  • Open a terminal.

  • What directory are you in?

  • What files are in the directory?

  • Can you list the files in the directory in different ways?

  • How do you go to a different directory?

  • What files are in that directory?

  • How do you see only a few of the files at a time? Say ones that begin with the letter 'a'?

  • How do you see only the .html files?

  • How do you copy a file?

  • How do you move a file to a new filename? Is that the same as renaming it?

  • How do you make a new directory?

  • How do you get rid of a directory?

  • How do you list the contents of a .txt or .html file to the screen?

  • How do you break a text file into screen-sized chunks if it is too big to display on the screen?

  • How do you show the first part of a text file to the screen?

  • How do you show the last part of a text file to the screen?

  • How do you find a file in a different directory if you know (part of) its name?


You should be able to use the reference list posted above to solve all these problems. If you're totally stuck, leave a note in the comments.

Then you can move on to some more Turkel questions. Characters in quotes are commands to type into your Unix terminal. Don't include the quotation marks:

  • What do the "uname", "hostname" and "set" commands do? (minus quotes)

  • Try "ls -l" and "ls -1". Read "man ls"

  • Practice using "touch". Read "man touch"

  • Practice using "grep".

  • Make sure you read about . .. ~ and / .

  • Read "man less"

  • Read about pipes and redirection (|, <, >, >>), sed, split, chmod, curl and lynx



Once you're done that, you can try out some of the free quizzes on the bdv-unix-skills website.

Hope that helps, and since I'm still learning too, more advice is most welcome!

Saturday, July 18, 2009

Google's Geographic Bias

If you're sitting in Atlanta, it makes sense that when you Google "Hair Dressers" you are probably most interested in services near to you. It doesn't do you any good to know "Jimmy's Haircut Shop" in Vancouver BC doesn't require an appointment; you need to know who in your area can cut your hair.

Google's searches have several mechanisms in place to help with this. For example, an American will automatically be directed to Google.com when they navigate to Google. Here in Canada, you get sent to Google.ca, and in Jolly Old England, you go to Google.co.uk. Each is designed to help users find search results most likely relevant to them. Canadians are more likely to see Canadian sites ranked higher.

However, this "helping" can effectively mean people in some countries are blind about what occurs elsewhere in the world. Many people do not look beyond the first page of results when they have performed a Google search. Hence the intensely competitive "Search Engine Optimization" industry that works hard to ensure sites are ranked highest. What this all means for a researcher new to the internet or unaware of the perils is that depending on where you live, Google might not point you to the same resources. This is especially the case if you are trying to research another region.

For example: the Google search for "england history" on the US, UK and Canadian instances of Google all provide 83 000 000 matches.

However, while the page "The History of England" ranks 6th on the UK version of Google, it is ranked 66th on the Canadian and American versions of the search engine, deep enough down that most people wouldn't likely bother to check it out.

If I were interested in the Network in Canadian History & Environment (NiCHE), hosted at niche.uwo.ca, and did a search for "niche", what I found would depend on where I lived:

Google.ca rank: 3rd
Google.com rank: 15th
Google.co.uk rank: 420th (that's the 42nd page!)

The .ca attached to the address means that Google has decided that this page is likely irrelevant to Brits. Now, granted, I should probably refine my search to get beyond the fact that a search for a word like "niche" is a bit ambiguous. But, the important thing to take away here is that Google is vetting what knowledge we find, in many cases without us even being aware of it.

What can we do about it? Probably not very much that will get Google to change their ways. But as responsible researchers and internet users, we should be aware of this. When you're doing research, make sure you don't just accept Google's top 10 suggestions at face value. Try another search engine (there's lots!). And if you're doing research on another country, make sure you try out their version of Google as well as your own.

Technology is great, but we've got to know it's limits.

Tuesday, July 14, 2009

Do You Have a Wiki Yet?

If you're doing research without a personal Wiki, you're livin the hard life. Whether you love or hate Wikipedia, you can't deny it's got appeal and a large part of that is the wiki environment. It's extremely easy to link pages together, edit and keep back ups of previous work all at the same time.

Working on multiple projects? A central wiki can branch off into each project and keep things organized for you.

Don't have a big research budget to spend on software? How's free sound? If you already have webspace you can install the open source MediaWiki, the same package that Wikipedia runs on. If you don't have server space of your own, try Wikispot who will provide free wiki access to anyone working on a collaborative project.

If you're concerned about privacy or having your unfinished research show up on Google Searches, fear not; there are ways to prevent search engines from Indexing your wiki, usually found in the preferences, depending on which wiki you use. If you're running your own wiki, you'll have the option to password protect it.

So, do you have a wiki yet?