Skip to content

Instantly share code, notes, and snippets.

View scarabaeus's full-sized avatar
🍹

Steve G. scarabaeus

🍹
  • San Francisco, CA
  • 14:59 (UTC -07:00)
View GitHub Profile
@scarabaeus
scarabaeus / p4merge-as-git-difftool.md
Last active January 31, 2025 21:10
Setting p4merge as default git difftool

Setting up P4Merge as the default difftool for Git

  1. Download P4Merge for your operating system: https://www.perforce.com/downloads/visual-merge-tool
  2. Run the .dmg file that you just downloaded.
  3. Copy only the P4Merge app to your /Applications folder. (Unless you want the other apps as well.)
  4. Run the following lines in terminal:
git config --global diff.tool p4merge
git config --global difftool.p4merge.path /Applications/p4merge.app/Contents/MacOS/p4merge
@KristofferBerge
KristofferBerge / web.config
Last active January 13, 2020 17:15
Configuration file for Azure web app to support angular2 applications with routing and long urls for auth tokens.
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.web>
<httpRuntime maxQueryStringLength="32768" maxUrlLength="65536"/>
</system.web>
<system.webServer>
<security>
<requestFiltering>
<requestLimits maxQueryString="32768"/>
</requestFiltering>
@roboshoes
roboshoes / touchmouse.js
Created April 13, 2012 10:43
This snippet maps mouse events and touch events onto one single event. This makes it easier in the code since you have to listen to only one event regardles whether it's desktop or mobile.
(function() {
/* == GLOBAL DECLERATIONS == */
TouchMouseEvent = {
DOWN: "touchmousedown",
UP: "touchmouseup",
MOVE: "touchmousemove"
}
/* == EVENT LISTENERS == */