Archive for Developer stuff

When I fell in love with git hooks

It actually wasn’t that long ago that I stumbled upon git hooks and let me tell you – I was instantly hooked (he he). Git has triggers that can kick off custom scripts to run before an action. These are especially useful to help you…

Continue reading →

How to set aliases in git

Aliases are lovely since you don’t have to write so many characters It’s easy to set up your own. Just go to your home catalog and edit your .gitconfig file Here’s mine:

Continue reading →

How to disable console log in NodeJS production

console.log is great! Everyone knows that. What’s not that great is that if you let it be in your source code you will get flooded logs on your NodeJS production server. Not that great. But don’t stress my friend. There is a easy fix for…

Continue reading →

Cross-Domain Tracking With Google Tag Manager and Universal Analytics

The good people over at Luna Metrics have made an awesome screencast on how to properly set up cross domain tracking using Google Tag Manager and Universal Analytics. You can read the original article here. Here is a step-by-step guide on how to correctly set…

Continue reading →

How to inject scope variable into callback properly – Node.js

We are working on a fun Node.js project at work. However, we were doing a for-loop with a callback and had big problems to pass in the variable into the callback-function. Either it was undefined or all entries had the same value. We had this…

Continue reading →

Starting out with Node.js

We are having a little hackathon at work today and tomorrow. We have been split up into 5 teams and my group is going to make a app that will talk with Google Calendar and will be able to show statuses for all our meeting…

Continue reading →

Mouse cursor/pointer disappears on Windows Server 2012 using Cord

I had a problem that my mouse pointer disappeared when I was remoting in with Cord to a Windows 2012 Server. Often the pointer had wrong context too, was showing a text pointer instead of the regular arrow. The trick to fix this is pretty…

Continue reading →

FIX: Capistrano deploy fails after changing repository URL

We have moved some of our clients repositories from Github to Bitbucket but when we tried to deploy we got the following error: I tried making a clean-up but that didn’t work. The solution however is pretty straight forward. You just need to login to…

Continue reading →

Regular expressions in Notepad2 (with backreference)

Regular expressions is really nifty to use when you got a chunk of data and need to extract or change certain parts of it. I’ve used it before in Notepad2 to replace mostly with empty strings but this time I wanted a little bit more….

Continue reading →

How-to: Make a cannonical redirect with Apache

Me and my goldfish brain tend to always forget how to make a proper cannonical redirect with Apache. So this is just a post for myself so that I don’t need to Google for it every time and read through posts with grade-A bullshit in…

Continue reading →

Page 1 of 2 1 2