How to: make a local copy of a website using the command line in Ubuntu written by: Lee Richmond posted on: 22 December 2009
I was recently asked to make a copy of a live website for reference purposes by a client of ours atCoolpink, I normally used HTTrack for this task as it's a really nice free piece of software and as well as having a GUI version (for both Windows and Linux) is usable via the command line in Linux.
However the last couple of times I had used it I noticed it was having problems when downloading images and cutting for no apparent reason, so I decided to look into other ways to do the task and it appears that it is relatively simple in the Linux command line using the wget command, simply type:
cd Desktop wget --mirror -p --html-extension --convert-links http://somewebsite.com
And in a matter of seconds of watching the command line spit out lots of text, a new folder titled www.somewebsite.com (obviously this will be what ever website you are making a copy of) appear on your Desktop with all the webpages downloaded as html files.
F**k you I wont do what you tell me!! ...but I will do what he tells me. written by: Lee Richmond posted on: 17 December 2009
So I'm pretty sure everyone has heard about this in some form or another by now, on Monday the winner of X-Factor released his first single just in time to compete for Christmas number one, but at the same time a campaign has been started to get the song "Killing in the Name of" by Rage Against the Machine to number one to keep the X-Factor winner from the top spot.
To be perfectly honest this whole thing seems pretty flawed to me, as it has been pointed out to me many times, the reason for choosing Killing in the name of is because of the lyrics "f**k you I wont do what you tell me!!"
This is meant as some form of protest towards the money making machine known as Simon Cowell, yet what strikes me as odd is that someone has turned around and told anyone who read the page on Facebook or where ever else they have heard about this, to go out and buy a copy of "Killing in the name of" either from the shops or from iTunes.
Now as far as I am concerned I don't like either song and would much rather see something like The Little Drummer Boy by David Bowie and Bing Crosby in the number one spot this Christmas, but surely in following the instructions of who ever started this protest, it strikes me that people are blindly doing as they are told only this time not by someone who stands to profit from it?
I posted my thoughts about this on my Facebook page yesterday and one response I got is that the same logic expressed above could be used for the majority of things we do in life. I don't know about anyone else but I wasn't told to become a web developer, I chose this career path because I wanted to do something that I am passionate about and that I enjoy. I was not told which house to rent I looked at various properties and made and informed decision based on what I had seen. I didn't swap my car for the one I have now because I was told to, I swapped it because I have a great love of Japanese cars and have wanted the car I've got for years.
All I can say is that if people genuinely believe that their path in life has been forged by doing as they are told, they should really go back and maybe re-think a few things
A long awaited update written by: Lee Richmond posted on: 20 October 2009
Well I know I've been majorly neglecting my blogging duties recently, There are a few reasons for this, the main one being that about 3 months ago I started working as the junior developer for Leeds based digital agency called Coolpink.
I am proud to be part of the dev team here because it means I get re affiliate myself with PHP, in some respects it has meant going back to basics (I didn't realise just how long it had been since I last did anything in PHP) but I am also now learning PHP in the context of the MVC framework the guys here have built, which so far I have been impressed with. This does not mean I am leaving my Ruby on Rails work behind me, however it has had to take a bit of a back seat for a couple of months, and I am hoping that at some point in the future I will get to showcase the beauty of RoR development to the rest of the team and maybe even get the opportunity to use it on projects in the future.
This career move has also given me an opportunity to finally start using the jQuery JavaScript Library, this is something I had looked into several times in the past but never really had the chance. I have to say I am really impressed with the how clean the code is and how easy it is to implement in your website, I will be implementing jQuery on here just as soon as I get a spare moment, if you have not already checked it out I urge you to do so.
Anyway that is all for now, I do have some more blog posts planned for the coming weeks so keep checking back you never know I may post something of interest
How to: Update your gem sources list on Ubuntu written by: Lee Richmond posted on: 11 August 2009
I recently wanted to edit my gem sources list to incorporate http://gems.github.com as I whenever I wanted to try a new gem I had found on there or more recently when I was doing a fresh install of everything on my home machine I was finding it pretty tedious having to go to github finding the link for the gem and adding it to the end of the gem install command.
However after doing a bit of reading I found that it is amazingly simple to update this list, so using the instance above to add github.com to my gem list I ran the following command from my terminal:
sudo gem sources -a http://gems.github.com
If it has worked you will get a message displayed saying that it has been added.
Also say for instance that you decide at some point you no longer what this item in your sources list simple type the following command to remove it:
sudo gem sources -r http://gems.github.com
and this will remove said item from the list.
how to: install Alsa with creative XFi support in Ubuntu written by: Lee Richmond posted on: 09 August 2009
Recently I had been having sound issues in Ubuntu but here is how I overcame them:
Step One: Download the latest version of the alsa-unstable-snapshot.tar.gz from here to your home dir.
Step Two: Now we need to make sure our system is able to compile these files by typing the following commands into your terminal:
sudo apt-get update
apt-cache search linux-headers-$(uname -r)
sudo apt-get install linux-headers-$(uname -r)
sudo apt-get install build-essential
Step Three: Next we need to make sure we're in home dir in Terminal and extract the files before we start to compile them:
cd ~
tar -zxf ALSA-driver-unstable-snapshot.tar.gz
cd ALSA-driver-unstable-snapshot
Step Four: Now you should be in your new extracted alsa dir, which contains all the relevant files, now we need to make sure the correct permissions are granted to the files we need:
sudo chmod 700 configure
Step Five: Now we start with the configuring and installation process:
first we need to run the configure file so in terminal type:
./configure
once that has finished the next step is to make the files:
make
and finally we install the package:
sudo make install
once this has finished you should restart your machine.
Step Six: at this point you will probably think that not much has happened, the reason for this is that by default the Alsa Drivers are muted, so now we need to adjust the volume via the Alsa mixer, so in our terminal type:
alsamixer
and using your left and right keys to move between the controls and the up and down keys to adjust them, adjust your settings accordingly.
now you need to check that you are using the Alsa drivers so again in terminal type:
gnome-sound-properties
and check that all the boxes read Alsa and thats it your Alsa drivers are now installed and will work with your lovely Creative XFi sound card.
End Note: IN the past I have found that PulseAudio seems to conflict with the Alsa Drivers i.e. sound cutting out etc. if you experience the same problems, all I did to resolve this was remove the PusleAudio drivers:
sudo apt-get remove pulseaudio pulseaudio-utils
NB I believe this has since been sorted in Ubuntu 9.10.



