How To

How to manage your time with Windows Mobile

If you are like me and are a Windows Mobile user, you might feel a little left in the shadows by all the iPhone love out there. I use the HTC Vox (actually Orange’s SPV E650) and find it a great little app. It’s got a slide out keyboard and is nice and small.

SPV E650

SPV E650

I am always trying out new ways to best use this device, so I thought I would share what I currently have settled on. First off, a little background about what I want to achieve from this device. I, like most normal users, am stuck behind a desk most of the time, I am not a road warrior, so I only need my device to help me out, not run my life. I mainly use it to  manage my time and make notes, not as my only work tool. Thus, I have concentrated on time management tools.

My main task management tool is WebIS’ PocketInformant, a replacement to the default Pocket Outlook installed on my phone. PocketInformant has a huge amount of options and allows you to define different calender views, add reminders about meetings, tasks and notes, as well as manage your contacts. My main use is to simply add any reminders that I need about project and task due dates, and also write notes about projects I am working on, alongside reminders for these notes.

PocketInformant

PocketInformant

My next tool is SBSH’s Facade. This is a home screen plugin that alongside adding shortcuts to as many apps as you want, meters for various phone stats, it also adds a handy calender preview right on the home screen. You can use it to instantly check up on task that day, simply by unlocking the phone to operate the screen. I find it incredibly handy.

Facade

Facade

Finally, as a bonus, if you also have SBSH’s Pocket Weather, you get a weather forecast in your home screen to ;)

Pocket Weather

Pocket Weather

Finally, to help me manage all my thoughts and ideas I have when I am on the move, I simply whack them down into the phone’s built in notes application – or Pocket Word depending on how big my blabbing will be. Then, I transfer over the file and copy and paste into a tiddlywiki file. Not the most elegant of solutions and I could edit the tiddlywiki file on the phone, but it seems like PIE isn’t designed for such a java heavy page.

So, this is how I work and it works great for me.

Tags: ,

Tuesday, November 25th, 2008 How To, Recommendations No Comments

Filter posts from RSS feeds

Ever had any posts from a feed you wish you didn’t have to read through (I know, the pain the heart ache, you have to actually scroll through a post you don’t like, man, we are so lazy us modern humans)? For example all the incessant drivelling about iPhone apps, or annoying adds in feeds, such as the ones that lifehacker have started to add, like the one below:

lifehacker feed add

lifehacker feed add

Now, if you are like me and find these adds annoying, you can get rid of them. There are a number of possibilities, but so far only one works at the moment, the rest might take time to work.

If you use Google’s Feed Reader and Firefox, you can try the Google Reader Filter for the Greasemonkey extension (and as mentioned by lifehacker themselves). This allows you to add filter words so that posts containing them are greyed out, the advantage being you still have the post to read if you want. However, I couldn’t get it to work and it only works in the list view. In fact, some comments on the scripts page indicate that it doesn’t work in Firefox 3 and that the script author is no longer maintaining it, so this might be a no-starter.

Next, you can try to write a Yahoo Pipes filter, such as this one here that I created. However, it doesn’t seem to work for me :( . This is more than likely due to my naff programming skills, you might have better luck.

Finally, there are two web services you can use, FilterMyRSS and FeedRinse. I haven’t had any results from FilterMyRSS yet, but so far FeedRinse has worked wonders. I simply added the full lifehacker RSS feed, then added a filter to block posts that contain [Sponsored] in the title. Then, subscribe to the feed in your favourite reader, and tada, gone are those annoying adds. Of course, you might have to update the filter based on how lifehacker changes how they present these adds ;) Of course, you can add any other term to filter out, like “iPhone” to remove all the iPhone drivel that fills lifehacker’s pages these days. The disadvantage with this solution is, you can’t see what feeds have been filtered out, so you don’t know if you are missing loads of posts that you don’t actually want to be filtered out. But hey, at least the adds are gone ;)

Tags: , ,

Sunday, November 23rd, 2008 How To No Comments

More backup goodness with rsync

So, a while ago I posted about how to use rsync and rsback to backup important files and folders. Wanting to be extra safe, I decided to create another backup on a separate disk stored somewhere else at home. This will act as a form of redundant backup. It wont backup everything that often, but I will always have something to fall back on in case both my main drive and backup drive fail, which is quite unlikely.

NSLU2

NSLU2

This solution uses the rather fabulous little NSLU2, a great little NAS device made by Linksys, I will post more about this little tool later.

Once again I decided to make use of rsync, since it seems like the best option and I was now more comfortable with it. I wanted my NSLU2 to pull data from my Ubuntu server onto a USB disk attached to the NSLU2. The best way to do this, is run an rsync daemon on the server and run rsync on the NSLU2 scheduled via cron.

First, you need to install rsync on the server, which I had already done for my previous backup solution, use synaptics and search for rsync if you haven’t got it installed already. Next, to get rsync to run in daemon mode automatically, you need to edit the /etc/default/rsync file and ensure that

RSYNC_ENABLE=true

Next, you need to create an rsyncd.conf file, located at /etc/, that controls how the daemon will operate. Now, you have to be carefull here with permissions, I had loads of problems with permissions before I figured this one out. You can set a number of options in the rsyncd.conf file to do with security and what folders can be accessed. Here is mine:

uid = root
gid = root
motd file = /etc/rsyncd.motd
log file = /etc/rsyncd.log
pid file = /var/run/rsyncd.pid
lock file = /var/run/rsyncd.lock


[backup]
path = /mnt/media/backupsfolder
comment = Media Disk Backup
uid = nobody
gid = nobody
read only = yes
list = yes
hosts allow = 192.168.1.142

The most important part is uid and gid, which determines what user the daemon runs at, whichever you choose, that user MUST have the correct permission to write to the directory that the log and pid files are stored. If you don’t choose a user with the correct permission, you will find that the daemon will run, but wont be able to transfer anything. The motd location and file is for the Message Of The Day, the file can contain whatever little message you want the rsync daemon to show when the rsync client connects. [backup] and what follows lists the folders that you want to make available for copying. You can have as many different folders as you want, each with their own [name] and file location. You can also change which rsync clients are allowed to read which file lists, using the hosts allow field. There are other options you can add here, to do with users and passwords, but I haven’t bothered since no one else on my network is using rsync.

Now that that is set up, you then need to set up the actual rsync client that does the pulling of the files on the NSLU2. I have decided to do this by a script that is run via cron. So, go create a script somewhere, I have stored mine at /etc/rsync/backuprsync.sh. When you create the file, make sure you make it executable, I chose chmod 744 /etc/rsync/backuprsync.sh. I wanted to have some details about the rsync process logged to a file, that was emailed to me, so, I added some extra code to the script. Here it is:


#!/bin/sh
echo Subject: Backup Backup Started on `date "+%m/%d/%y %l:%M:%S %p"` > /mnt/disk/backuprsync.log
rsync -av --stats rsync://192.168.1.111/backup/ /mnt/disk/backup/ >> /mnt/disk/backuprsync.log
echo END: Backup Backup Complete on `date "+%m/%d/%y %l:%M:%S %p"` >> /mnt/disk/backuprsync.log
cat /mnt/disk/backuprsync.log | ssmtp someaddress@gmail.com

What this does is first removes rm the old logfile (so make sure when you first run this, there is a log file there, otherwise the script will fail ;) It then prints the time the backup started echo Subject:... to some location I have chosen /mnt/disk/backuprsync.log. Next is the actual rsync command. The -av --stats options creates an archive file (a), creates detailed output (v) and creates some stats at the end (stats). rsync://192.168.1.111/backup/ is the address for the Ubuntu server based on its IP address, whilst backup is the name of the file location set up in the rsyncd.conf file. If you want to change the backup job to another file location, then just change backup to whatever you called the other job. /mnt/disk/backup/ is the location on the NSLU2 where the backup is stored. Finally, >> /mnt/disk/backuprsync.log will output the results of -v and –stats to the log file (by the way using >> instead of > means it appends the output, instead of overwrites it).

The next echo command prints when the job has ended to the end of the log file, as before (note the use of >> to append, rather than overwrite). Finally, cat /mnt/disk/backuprsync.log | ssmtp someaddress@gmail.com takes the log file and emails it to me using ssmtp. I had to use this as the OS I am using on the NSLU2 doesn’t have its own mail command. There will be more about setting up ssmtp in another post.

Finally, you’ll want to run this job via cron, so, add

01 1 3 * * root /etc/rsync/backuprsync.sh

To your /etc/crontab file. Ensure that your crontab file knows to use the sh shell, so it should have SHELL=/bin/sh at the beggining of your crontab file. This crontab entry makes cron run the script at 01.13am on the 3rd day of every month.

If all goes to plan, rsync will connect to your server’s rsync daemon, suck all the changed files from last time to the NSLU2 and then email you the results. Sweet.

Tags: , ,

Thursday, November 20th, 2008 How To 1 Comment

Setting up virtual hosts with Apache

Thought I should post about setting up virtual hosts in Apache, since this was one of the first things I had to do. I got all this info from this site, which was incredibly useful. For all the following instructions, when you see these instructions:

enter some/text/here

You need to enter this text exactly as you see it in your terminal, which can be found at Applications>Accessories>Terminal

First, you need to set up your folders where the sites are gonna be stored:

mkdir /home/www/www.example.com
mkdir /home/www/www.example.net

Then you need to tell Apache that you are gonna use virtual hosts. Create a file using:

sudo touch /etc/apache2/conf.d/virtual.conf

You need to add the following content, use:

sudo gedit /etc/apache2/conf.d/virtual.conf

and enter the following:

#
#  We're running multiple virtual hosts.
#
NameVirtualHost *

Now, you have to create an entry in both the sites-enabled and sites-available directories in /etc/apache2. So, first create the following file:

sudo touch /etc/apache2/sites-available/www.example.com

and enter the following by using:

sudo gedit /etc/apache2/sites-available/www.example.com

and enter:

#
#  Example.com (/etc/apache2/sites-available/www.example.com)
#
<VirtualHost *>
        ServerAdmin webmaster@example.com
        ServerName  www.example.com
        ServerAlias example.com

        # Indexes + Directory Root.
        DirectoryIndex index.html
        DocumentRoot /home/www/www.example.com/htdocs/

        # CGI Directory
        ScriptAlias /cgi-bin/ /home/www/www.example.com/cgi-bin/
        <Location /cgi-bin>
                Options +ExecCGI
        </Location>

        # Logfiles
        ErrorLog  /home/www/www.example.com/logs/error.log
        CustomLog /home/www/www.example.com/logs/access.log combined
</VirtualHost>

Next, do the same for your second site, so create a file using:

sudo touch /etc/apache2/sites-available/www.example.net

and enter the following by using:

sudo gedit /etc/apache2/sites-available/www.example.net

and enter:

#
#  Example.net (/etc/apache2/sites-available/www.example.net)
#
<VirtualHost *>
        ServerAdmin webmaster@example.net
        ServerName  www.example.net
        ServerAlias example.net

        # Indexes + Directory Root.
        DirectoryIndex index.html
        DocumentRoot /home/www/www.example.net/htdocs/

        # CGI Directory
        ScriptAlias /cgi-bin/ /home/www/www.example.net/cgi-bin/
        <Location /cgi-bin>
                Options +ExecCGI
        </Location>

        # Logfiles
        ErrorLog  /home/www/www.example.net/logs/error.log
        CustomLog /home/www/www.example.net/logs/access.log combined
</VirtualHost>

Finally, you need to create a copy of these files in the sites-enabled directory, using what is called a symbolic link. You can use a funky little program called a2ensite to do this. So, enter the following:

sudo a2ensite www.example.com
sudo a2ensite www.example.net

And finally (I was lying last time), you need to restart Apache for this to all take effect:

sudo /etc/init.d/apache2 reload

And tada, it should all be working, yay!

Tags: ,

Tuesday, November 11th, 2008 Set up a blog No Comments

Setting up WordPress

Formatting and Structure

One interesting thing I just noticed. When you write a page, and presumably a post, and WordPress creates a permalink for you, make sure you know what you want to call it, and don’t change it. It seems that wordpress uses the first title you choose as the permalink title. Even if you change the title later, it uses the original title as the permalink. Something to bear in mind when you get home late, drunk, and decide to write a rant about curbs and giving it a less than gregarious title…Ooh, I’ve just noticed you can edit it, in the permalink option beneath your page title..very cool.

Tags: , ,

Tuesday, November 11th, 2008 Set up a blog No Comments

Setting up Apache

mod_rewrite

After getting Apache up and running in Ubuntu, I needed to make sure it was all configured for WordPress. Everything was ok, excpet for mod_rewrite, which I apparently needed to enable. After some googling googling, I realised I needed to do this:

First, I needed to add the rewrite.load to /etc/apache2/mods-enabled/
So, open a terminal window and type:
sudo ln -s /etc/apache2/mods-available/rewrite.load /etc/apache2/mods-enabled/

Second, edit the apache configuration for my virtualhosting. For example, in my computer I only have one virtual hosting (/var/www) that is default from installation, so I make some adjustment for that (In my case I have to edit this file /etc/apache2/sites-enabled/000-default)
Again in terminal type (this loads a text editor with the correct permission allowing you to edit the file:
sudo vi /etc/apache2/sites-enabled/000-default
Change the Allowoverride value to all for the document root directory
For example, I made change to this part of the configuration:

/var/www/
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order allow,deny
allow from all
# This directive allows us to have apache2's default start page
# in /apache2-default/, but still have / go to the right place
# Commented out for Ubuntu
#RedirectMatch ^/$ /apache2-default/

Finnaly, just restart the apache, so, again in terminal type:
sudo /etc/init.d/apache2 restart

.htaccess

I wanted to get WordPress to use nice page structures, rather than all that silly ?>443634 stuff. So, in settings in WordPress, I chose the permalink option and decided on the day,date,name option. However, for this to work, as wordpress warned me, I needed to allow wordpress to write to my .htaccess file.

The .htaccess is a file that can be used to do a lot to change the way your site works, it can be used to add security to your site (all though this isn’t always the best way). It turns out that my site didn’t have a .htaccess file, so I had to create one, this was as simple as creating an empty file in the root of my websites directoy and calling it, yes, you guessed it: .htaccess.

I then had ensure wordpress can write to this file. I did this temporarly (by typing sudo nautilus into terminal, which opens a file explorer, but as the super user, so you can do what you want (carefull, you can kill your system if you delete a file that is needed) and navigating to the root of my website directory and right clicking on the .htaccess file I created and choosing the permissions tab and changing the option so everyone can read/write the file and click OK). I then chose the correct option in wordpress via the admin interface to make fancy URLs. WordPress now no longer moans about not be able to write to the .htaccess file. Now, I go back to the .htaccess file in nautilus, right click it again and chase the permission for everyone back to read only. Ta da – fancy URLS and some security to boot.

Tags: , ,

Tuesday, November 11th, 2008 Set up a blog No Comments

Search

 
If you like what you read, please donate via PayPal;)

Support Me

Get a free Giffgaff Sim

Sponsors

Sponsors