henning glatter-götz

Git merge specific files from one branch into another

I have started to use git branching more heavily in recent months and also make it a point to have small and well documented commits. This sometimes leads to the need to merge specific files from one branch into another (good or bad, it just happens). Git facilitates this with checkout:

1
$ git checkout source-branch-name/commit-sha path/tofile/of/interest

If you do not provide the commit sha it will simply checkout the file at the HEAD of the source branch.

Things I would like to learn in 2013

There are a number of new (and not so new) things I would like to learn or have been meaning to learn. Maybe putting them down on “paper” will serve as a reminder and I can revisit this at the end of the year.

So here is my list:

  • ember.js: I have always shied away from front-end development because I felt like it is horribly messy compared to server side code. But with the rise of so many Javascript frameworks and the huge surge in popularity of JS due to things like node.js and the Appcelerator Titanium platform I feel like the time might be right. Ember.js looks extremely promising and interesting.

Bye bye 2012

This year was certainly tumultuous!!

  • Had another big “0” Birthday
  • Had a second child - a daughter
  • Moved to a different continent

Those are some major changes that definitely caused some moments of temporary insanity, some where longer than others and seemed to never end. But I am still standing!

./symfony doctrine:build-schema for a Single Table

The built-in command line tasks in symfony 1.4 (yes, I am still stuck on 1.4) are very handy for quickly performing all sorts of project related tasks. Doctrines own command line tasks are exposed through the symfony CLI in the doctrine namespace. I use the doctrine:build-schema task, which generates a yml schema for an existing database, all the time. This allows one to very rapidly build models from and for an existing database.

PHP: The Right Way

Today I discovered an interesting new project called “PHP: The Right Way”. It is an open source project maintained by Josh Lockhart attempting to provide a well rounded set of best practices for developing in PHP.

While I have not yet attempted to contribute any content I have added the banner to my personal blog to show my support. If you are interested it adding a “PHP: The Right Way” banner to the side bar of your Octopress blog, here is how. Allthough, if you are using octopress you probably don’t need help with this ;-).

ExactTarget SOAP API: Obtaining an Accurate List of Retrievable Properties

Aahhh! The joys of integrating with third-party API’s. Trying to get your application to talk to a third-party API is sometimes tricky, especially if the API documentation is not up to date. SOAP is supposed to make this simpler by providing a WSDL from which you can generate classes. So what are you supposed to do if the documentation and the WSDL seem out of date?

Appcelerator Titanium - A Nice Looking Activity Indicator Window

UPDATE (April 11th 2013):

I updated the demo project on github with a patch from Khawar. The demo now also works on android.

The Titanium.UI.ActivityIndicator is a commonly used component in my iOS applications, but on its own it does not look very appealing. To make the activity indicator look a little nicer I dressed it up in its own window that has is slightly opaque and stuck it in a commonjs module.

ExactTarget SOAP Upsert with PHP

There is quite a bit of documentation for the ExactTarget SOAP API that includes lots of code samples. But unfortunately the PHP code samples are not quite as plentiful as the .NET and Java ones. After lots of searching and lot of trial and error I finally got my upsert working. An upsert is a SOAP method in the ExactTarget SOAP API that will either update or insert a record depending on whether it is already present or not.

Connecting to Microsoft SQL Server from PHP on OSX and XAMPP

UPDATE (March 23rd 2012):

I recently found a PHP binary that has a one-line installer. It is actively maintained by Liip AG. I now use that in combination with HomeBrew for all the rest. The Liip package is compiled with pdo_dblib which makes the problem described in this post a non-issue.

I recently found myself in the position of having to connect to a remote Microsoft SQL Server from my OSX system using PHP. The production environment runs Ubuntu LINUX, where connecting via mssql_connect() was no problem, but I develop on OSX and I could not get this to work initially.