How To Split Amazon Payment Between Two Credit Cards
In the process of purchasing all the new goodies for my new place I decided now would be a good time to exercise a line of credit through Amazon. Unfortunately Amazon gave me a lackluster credit limit that only covers about 1/4th of my carts total.
I now need to split the payment across two payment methods. The credit card issued by Amazon and my Visa debit card. This is problematic because while Apple’s online store offers a way to do this, Amazon does not. Fear less, I’ve figured out a simple way around this limitation – Amazon’s Gift Cards.

Purchase an Amazon Gift Card with one payment source. In my case I purchased a gift card with my Visa debit card.
You can purchase your Amazon gift card here:
http://www.amazon.com/gp/product/B004LLIKVU/?tag=amz-gift-card-20
Select the email gift card, set the amount, and send the gift card to yourself. You will be emailed a code. Copy that code as we will use in the next step.
- This is not limited to two payment sources. You can purchase a gift card with each payment source you have.
- It appears $2,000 is maximum gift card amount you can purchase.
- It can take up to 15 minutes to receive the gift card.
Now that you have your gift card code, when you go to select the payment options for your cart you’re able to select a primary payment source – in my case my Amazon credit card.
Then input all of your Amazon gift card codes as secondary payment source.

That’s all there is to it. Hope this hack helps other!
Django 1.5 Custom User GeoManager
AttributeError: ‘GeoManager’ object has no attribute ‘get_by_natural_key’
Using geo fields on a Django model requires the use of GeoManager. Custom User models require an object manager that implements BaseUserManager.get_by_natural_key. If you’re trying to add geo fields to your custom User model you’ll need create a custom manager that mixes a user manager and GeoManager. Lucky us, this is a piece of cake!
Create Text & Online Versions of Emails Automatically
For this i’ve created django-firstclass. Firstclass is a proxy email backend for Django that allows for global email transformations such as automatically creating a plain text version of html emails or automatically creating an online version of the email that can be read in browser.
My goal was to have this be a drop in solution requiring no change to a code base. I also wanted this to be flexible enough so that it can work with a wide variety of projects. I accomplished this by adding a middleware pipeline to Django’s email process. I’ve bundled a few useful middleware in and plan to add a few more. Creating your own middleware is simple. Middleware is a single Python class that defines process_message.
For example if you wanted to create a middleware that would add a tracking pixel to all of your emails:
http://gist.github.com/3048960
You would then simply add TrackingPixelMiddleware to FIRSTCLASS_MIDDLEWARE.
Currently 99% of All Backbone.js Apps Are Broken
Javascript and Backbone.js is an async world. This also means request are async. If you’re fetching results for a collection and blindly expecting your collection to match those results, showing them to a user – you’re gonna have a bad time.
Currently slow request can cause havok on the the state of your collections and models. Imagine this scenario: A user search for ‘javascript’ first and then ‘dom’. The ‘javascript’ search hangs so the user never got to see the results. They then search for ‘dom’ and that response comes in right away while the ‘javascript’ search is still pending. The user is presented with books on ‘dom’. The old ‘javascript’ request now responds. The collection and the users UI is abruptly changed to books on ‘javascript’. Not good! backbone-safesync tries to remedy this by aborting old request.
https://github.com/amccloud/backbone-safesync

Thanks to rpflo in #documentcloud for bringing this to light.
Backbone Bindings
When working with Backbone it is common to re-render a whole view when a model attribute has changed. We can do better than that. Inspired by bindings in Cocoa (iOS & Mac) applications, I’ve created a library that allows you to bind element properties to model attributes, with optional transformation in between. I wanted bindings to be as simple as Backbone.View.events.
http://gist.github.com/2691450
See it in action here: http://jsfiddle.net/T2MSu/3/
https://github.com/amccloud/backbone-bindings

Backbone Dotattr
I’ve created a little utility for accessing deep attributes in Backbone.js models with dot-syntax.
http://gist.github.com/2663112
https://github.com/amccloud/backbone-dotattr

TextMate 2 Bundle Directory

~/Library/Application Support/Avian/Bundles/
The application support directory has been renamed so that it does not interfere with TextMate 1 bundles. From my testing (not absolute) TextMate 1 bundles work with TextMate 2.
Quick Optional Model Fields Trick
This is just something I do now. It’s DRY, saves a few keystrokes, helps stay under pep8’s 79 character limit, and improves readability in my opinion.
Custom Facebook Chat Smileys! Rage Face, Domo Kun, and more!
Poker Face [[129627277060203]]
Forever Alone [[227644903931785]]
OK Guy [[100002752520227]]
Me Gusta [[164413893600463]]
LOL Guy [[189637151067601]]
Fuck Yeah [[105387672833401]]
Problem? [[171108522930776]]
Yao-Ming [[218595638164996]]
Troll Face [[171108522930776]]
Are you kidding me? [[143220739082110]]
Not bad Obama [[169919399735055]]
Mother of god [[142670085793927]]
Cereal Guy [[170815706323196]]
Socially akward penguin [[98438140742]]
No [[167359756658519]]
Gentleman [[168040846586189]]
Challenge Accepted [[100002727365206]]
Domo Kun [[250128751720149]]
Pokeball [[236147243124900]]
Pikachu [[326134990738733]]
Spongebob [[334954663181745]]
Pedo bear [[148935948523684]]
Dark Letter A [[107015582669715]]
Dark Letter B [[116067591741123]]
Dark Letter C [[115602405121532]]
Dark Letter D [[112542438763744]]
Dark Letter E [[115430438474268]]
Dark Letter F [[109225112442557]]
Dark Letter G [[111532845537326]]
Dark Letter H [[111356865552629]]
Dark Letter I [[109294689102123]]
Dark Letter J [[115636698451811]]
Dark Letter K [[116651741681944]]
Dark Letter L [[115807951764667]]
Dark Letter M [[106596672714242]]
Dark Letter N [[108634132504932]]
Dark Letter O [[116564658357124]]
Dark Letter P [[111669128857397]]
Dark Letter Q [[107061805996548]]
Dark Letter R [[106699962703083]]
Dark Letter S [[115927268419031]]
Dark Letter T [[112669162092780]]
Dark Letter U [[108983579135532]]
Dark Letter V [[107023745999320]]
Dark Letter W [[106678406038354]]
Dark Letter X [[116740548336581]]
Dark Letter Y [[112416755444217]]
And for the holidays!
[[106596672714242]] [[115430438474268]] [[106699962703083]] [[106699962703083]] [[112416755444217]] [[115602405121532]] [[111356865552629]] [[106699962703083]] [[109294689102123]] [[115927268419031]] [[112669162092780]] [[106596672714242]] [[107015582669715]] [[115927268419031]]
Also don’t forget to checkout custom Facebook timeline covers over at changecovers.com




