Django: Using ModelAdmin to default to currently logged in user
Yeah, you may have noticed that I've been working on the blog lately. Poor openclue.org got flooded with already posted RSS feeds again. This happens all to often. Sorry guys.
Yeah, you may have noticed that I've been working on the blog lately. Poor openclue.org got flooded with already posted RSS feeds again. This happens all to often. Sorry guys.
At work, I use git. For Exaile I use bzr. I like them both quite a bit. At work, we use Gitosis to manage our repositories and I have to say, it's pretty damn cool. Nothing quite like this exists for bzr, so I ported Gitosis to bzr and called it Bazitis. The launchpad project page can be found here. Here are the instructions on how to use Bazitis:
I noticed that every time Clint Savage makes a blog update, he posts the URL to Twitter twice (yeah, that's you herlo :P). The URLs for each Twitter post are different, so I figured it must be some sort of automated Wordpress script with a bug in it...
A nice fellow emailed and asked me if I could post a monthly (possibly weekly) roundup on Exaile 0.3 so that people can follow what's going on. It sounded like a good idea to me, so here's the first one.
Django 1.0 is finally here!!!
Exaile is currently undergoing an almost complete rewrite. Why? Because the
codebase could be better. Recently, thanks to Aren Olson, the 0.3 branch has
been taking off. Already the code is a lot better, and will be a lot easier to
add things to in the future.
As of this writing, you can create a
collection, based on different libraries (directories). For each one of these
directories, you can set a rescan interval, and/or have the library be watched
by pyinotify for changes. You can create playlists, smart playlists, play
these playlists in order or shuffle and/or on repeat. I am currently using it
as my default player.
However: none of this can be done using a gui
yet. This can all be done easily by using Exaile 0.3's pretty good looking
internal API. Here is an example...
A few versions ago, Exaile had Last.FM streaming support using LastFMSource,
a pygst plugin created by Philippe Normand of Elisa. It worked... sort of. Every other
time you tried to connect to LastFM station, Gstreamer would lock up entirely,
taking Exaile out with it. Not being able to fix this problem, it was
eventually removed from Exaile entirely.
Enter: LastFM Proxy...
At SendOutCards, we use MySQL replication to ensure that if our main database server goes down because of hardware failure, we'll still have an server that is up to date with our data. In a nutshell, our main database server sends another server every update that is performed on itself...
Vimtips.org is running the SVN version of Django. This morning I ran an
svn update
, and I ran into my first API change. While looking at
my site later on in the day, I noticed that both of my template filters were
being HTML escaped, IE, things like < were showing up as
<...
As stated on his blog, Josh Simpson came up with the idea of creating a Gallery/Gallery2 replacement in Django. He's rounded up me and a couple other of our good friends to tackle this project...
Django is a "high-level Python Web framework that encourages rapid development and clean, pragmatic design." So far, I have absolutely no complaints... and much praise.
GNOME 2.18 introduced a new way for applications to handle multimedia keys. Previously you have to muck around with X events, while now GNOME does it for you and you can get control of mmkeys by requesting through D-Bus (to GNOME Control Center’s Settings Daemon). All good until you realise that for cross-desktop support you still need the old method anyway—unless, like Rhythmbox and Banshee, your app is GNOME-based.
This article shows how we support both methods in Exaile, and how you can do it, too.
I came across the following code a while ago. I can't take credit for it, and I can't remember where I got it. Oh well. It's pretty cool nonetheless.
Here's a little info about how/why I got into vim...