ios8 today app extension

Today App Extension Experiments on iOS 8

I’ve played around with the Today App Extensions that has been introduced with iOS 8.

Sample Code

There’s a nice blog post/tutorial by Lammert Westerhoff creating a more advanced sample extension than the iOS template by Apple.

Simulator

Most of the time the simulator does not run the current code with Xcode 6.0.1. You have to manually reset the simulator and run the current extension again to see the newest results. Hope this gets fixed in the next release.

App Bundle

Unfortunately you have to create a real app next to the today extension. I can imagine that in most cases you want simple today extension settings dialogs where you can setup your extension and don’t want a big fat app to distribute.

Local PostgreSQL Setup

Shell configuration (~/.bashrc, ~/.zshrc, …)

export PGDATA=~/anywhere/postgresql_data # PostgreSQL data directory
export PGHOST="/tmp"
alias pgstart="pg_ctl start"
alias pgstop="pg_ctl stop"

Initial setup

$ initdb -A md5 -E UTF8 -U $USER -W

$ vim $PGDATA/postgresql.conf

listen_addresses = 'localhost'

$ vim $PGDATA/pg_hba.conf

# TYPE DATABASE USER ADDRESS METHOD
# ADD THE FOLLOWING LINE AND REPLACE 'YOUR_USER' by $USER
local all YOUR_USER trust

Start/Stop PostgreSQL

$ pgstop
$ pgstart

Important commands

$ createdb database_name # create new database
$ dropdb database_name # drop database
$ psql -p # list all available databases
$ psql database_name # connect to database

psql console

\? # help
\d # list tables (and other things)
\d table_name # show table schema

Kanbanery overview with banery_stats

I’ve created a very simple gem called banery_stats to view my #tasks for every project for my kanbanery account.

It’s very simple to use. First you have to manually get your kanbanery api token. Afterwards it’s as simple as:

$ export KANBANERY_API_TOKEN=my_token
$ banery_stats
WORKSPACE name0 #projects: 2
0 project1
3 project2
WORKSPACE name1 #projects: 3
3 project3
12 project4