Bugify can now be downloaded from bugify.com and as always, the demo is available at demo.bugify.com
Using Google Analytics with Sencha Touch (queues while offline)
The Google Analytics ga.js script is designed to work with cookies, but as your Sencha Touch app is probably running through something like PhoneGap, it is being accessed using the file:// protocol, so no cookies – which means that if you simply include the normal Google Analytics script, nothing will happen.
The heart of the ga.js file is loading the __utm.gif image, with a number of parameters that Google then uses to generate your stats. Most websites just track page loads, but again, with a Sencha Touch (or any javascript-based app running locally) there is generally only one page load.
The best way to track usage with Google Analytics in a javascript-based app running locally – that I have found – is to use “events”. You must trigger these events for things that you want to track (e.g., in Sencha Touch you probably want to track the “cardswitch” event on your viewport). You can find more info about events with Google Analytics at http://code.google.com/apis/analytics/docs/tracking/eventTrackerGuide.html
It’s important to understand how “events” work with Google Analytics, so please read that page… now that you have read it, you need to know that you won’t be using the _trackEvent method. You don’t even need to include the ga.js script.
Back to how ga.js works for a moment: if you use _trackEvent on a normal website, every time you call it, another __utm.gif file will be loaded with the event parameters – that is how the event details get back to Google.
The way we can track events in a Sencha Touch app is to load the __utm.gif file with certain parameters. You can find the list of possible parameters at http://code.google.com/apis/analytics/docs/tracking/gaTrackingTroubleshooting.html (scroll down to the bottom of the page).
The way I have implemented event tracking in my apps is by queuing the events, then batch loading the __utm.gif file when it has either a maximum number of events in the queue, or after a set interval, or if the app was offline for a while, then when it comes back online it will process the queue. I have a simple-to-use method with 3 parameters (category, action, label – these are the main parameters for event tracking) that I call when I want to track another event.
Hopefully this brief intro into how you might implement event tracking gives you enough to create your own implementation. If you are having trouble tracking events in your Sencha Touch (or other js app) then let me know and I should be able to share some of my code with you.
Bugify – PHP Issue Tracker
So, another project I have been working on for a while is Bugify.
Bugify is a simple PHP/SQLite based issue tracker. I have gone with SQLite again (same as Inspectify) because it makes for a much easier installation process for everyone – and performance is fantastic. I’m very aware that there are already tons of issue tracking systems around, but the problem I found was that most of the good ones were hosted services – but I, along with many others, prefer to keep certain information out of the so called “cloud”.
I have used many different issue tracking systems before (both hosted and self-install) and from my experiences, I wanted something that met the following requirements (in no particular order):
- It has to look good – I spend a ton of time each day looking at issues, so I want it to look good.
- It has to be fast.
- It needs to have an API so I can get my data in and out.
- It must be self-hosted.
- It needs to be simple – a lot of issue trackers go overboard.
So, from there I came up with Bugify, and I think it’s pretty good. Below are some of the other features that may make it into (or have already made it into) Bugify:
- Poll a mailbox for new issues.
- Detailed filtering.
- Save filters for easy access.
- Import from some other popular issue trackers (haven’t finalised which ones yet).
At this stage, I am using Bugify full-time, but it’s not ready to be released – there are a few features that haven’t yet been implemented. But, I could use some testers if you’re interested (sign up at bugify.com).
Update: you can now play with a demo at demo.bugify.com
Inspectify has been released!
Inspectify is a new code review tool. It’s designed to be downloaded and run on your own server. Have a look.