You are hereBlogs / David Grant's blog
David Grant's blog
I have a simple video website for my kids and each kid has a separate login. This is so they can each have their own videos, but also so that some videos can be private (ie. hidden from the outside world, or other logged in users). Typing in a username and password is impossible for my kids to do, as they are almost 5 and 2 years old, and they use this website on Google TV. So, with a magic token-style login, all they need to do is navigate to their bookmark on the Google TV homepage and press OK on the remote control.
I recently renamed a folder in my copy.com folder and caused Copy.com to think that I had deleted it. For example, I had the a folder called "Photos 2013." I installed the copy.com agent on a new computer and it began syncing. Midway through the sync, I wanted to change the folder's name to "Photos 2013-2014". This was interpreted as "Delete 'Photos 2013' folder and all sersver-side contents" and create a new folder called Photos 2014 with the photos in it. So let's say there were 100 photos, and 10 were were synced when I did it.
To wipe a hard drive using zeros:
dd if=/dev/zero | pv -s 250000000000 | dd of=/dev/sdX bs=10M
To wipe a hard drive with random data (more secure):
dd if=/dev/urandom | pv -s 250000000000 | dd of=/dev/sdX bs=10M
For the "pv" progress bar, do "apt-get install pv" or similar. I highly recommend using "pv" so you have some idea of when the dd job is going to finish.
I just set up a site using Django-CMS over at Pomme d'Api Preschool. Overall, I am pretty impressed. I really like the Django admin interface enhancements as well as the site overlay editing feature. One of the best things it he use of django-filer, a file management tool to manage all the uploads to the site. It's awesome and it makes me want to throw out this home page completely and switch over to Django-CMS. Image handling in Drupal has always sucked and still does.
If you ever get something like this:
Running /usr/bin/svn add -N --targets /tmp/svn_load_dirs_ErUQhjXmWG/targets.00001 /usr/bin/svn_load_dirs: /usr/bin/svn add -N --targets /tmp/svn_load_dirs_ErUQhjXmWG/targets.00001 failed with this output: svn: warning: W150002: '/tmp/svn_load_dirs_ErUQhjXmWG/my_import_wc/scripts/drupal.sh' is already under version control svn: warning: W150002: '/tmp/svn_load_dirs_ErUQhjXmWG/my_import_wc/scripts/run-tests.sh' is already under version control
I was working on a personal website for my kids where I can post videos for them and I noticed that for each video link that was displayed on the page there were 2 additional SQL queries. One to get the username of the user that added the video link, and another to get the list of categories for the link.
The model looks like this:
class Link(models.Model): ... # There was an extra query per link to get the categories for a link category = models.ManyToManyField(Category)
I've been maintaining and old Joomla 1.5-based website for my daughter's preschool, Pomme d'Api. It got hacked, I'm not sure how, via FTP or PHP but they basically managed to get 2 .php files on the server that were causing search engine crawlers to get a different version of the site that contained all sorts of links to various pages. It also changed the meta-information such as keywords and description.
I hate hashtags. At least they way that people use them. People seem to like using them to say things they wouldn't normally say in plain English. For example:
Why won't my kid take a nap? #damnkid #brat #nomorekids
This doesn't translate exactly into the following:
My damned kid won't nap
My kid is a brat
I don't want any more kids
I'm tired of all this social networking bullshit. I mean the social networking bullshit that is always asking me to click something, creating visual noise, and generally just pissing me off because I'm not interested in sharing everything I do with the world. Today I purchased some books at Chapters and after my purchase went through I got this screen asking me if I want to "tell my friends about my purchase" on Facebook, LinkedIn, or Twitter.
[img_assist|nid=403|title=Chapters - Share Your Purchase|desc=|link=none|align=left|width=501|height=233]
I just tried Windows 8, and to be honest it's pretty awful. It looks like it's meant for running on a touch screen but if you are a desktop user it's horribly awkward to use. I'm not sure if it's a bug but getting the task bar thingy (what's it called?) to show up on the left-hand side of the screen is very difficult. I seem to have to hover on the top-left corner and wait for an icon to appear, then move downward, then the whole task bar thingy will appear.
So I have a django database I'm working on and I decided I wanted to do the development in sqlite3 instead of mysql. I decided to do this because it makes it easier, for example, to have someone else work on HTML/CSS if I can just give them a directory, tell them to run a bash script and go to http://localhost:8000, rather than them having to do all that AND setup a mysql server. Sure, that can also be done with a script, but with sqlite things are just a hell of a lot easier in some ways.
A few days ago the B.C. government announced a new $10,000 bonus for new home buyers. Not only is this a stupid waste of money that could have been diverted to many more important things, it may not actually do anything to improve affordability as housing prices will surely go up accordingly.
We ordered a bunch of shoes online for my daughter, from various American companies. One of them was Preschoolians (I'm not going to link to their site. There is an entire blog devoted to how much Preschoolians sucks but the last post was from 2006 so I decided to give them a try anyways.
I'm just trying out Linux Mint Debian Edition and the best part about it is how fast it is. The desktop is super responsive, almost feels like a new fresh Windows machine in that respect. User switching is also super fast and works perfectly, something that Ubuntu had never quite mastered. Most importantly, however, is the fact that it is not using Canonical's Unity, but instead it is still using Gnome 2.
I just had a listen to this CBC interview with some writer about the housing situation in Vancouver: Young Adults Leaving Vancouver.