Skip to content

Instantly share code, notes, and snippets.

View phdoerfler's full-sized avatar

Philipp Dörfler phdoerfler

View GitHub Profile
@phdoerfler
phdoerfler / p4merge install
Last active June 14, 2022 14:41 — forked from AaronGhent/p4merge install
Installs p4merge on a linux based machine
# p4merge for 64 bit
wget 'https://www.perforce.com/downloads/perforce/r22.1/bin.linux26x86_64/p4v.tgz'
tar zxvf p4v.tgz
sudo cp -r p4v-* /usr/local/p4v/
sudo ln -s /usr/local/p4v/bin/p4merge /usr/local/bin/p4merge
@phdoerfler
phdoerfler / Focusmate_num_sessions_v1.rb
Created January 19, 2022 15:08 — forked from seyonv/Focusmate_num_sessions_v1.rb
File to get the current total number of sessions in Focusmate
require 'json'
require 'pry'
require 'uri'
require 'net/http'
class FocusMateNumSessions
# Step 1. Create a file somewhere in your filesystem.
# Call it fm_token_file.txt. Insert the path to the file into the line below
# Make sure to look at the reference .txt file and just paste
# that over.
@phdoerfler
phdoerfler / PomDependenciesToSbt.scala
Last active June 24, 2020 21:37 — forked from dportabella/PomDependenciesToSbt
Script to convert Maven dependencies (and exclusions) from a pom.xml to sbt dependencies. Or run it online on http://goo.gl/wnHCjE
#!/usr/bin/env amm
// This script converts Maven dependencies from a pom.xml to sbt dependencies.
// It is based on the answers of George Pligor and Mike Slinn on http://stackoverflow.com/questions/15430346/
// - install https://github.com/lihaoyi/Ammonite
// - make this script executable: chmod +x PomDependenciesToSbt
// - run it with from your shell (e.g bash):
// $ ./PomDependenciesToSbt /path/to/pom.xml
import scala.xml._
@phdoerfler
phdoerfler / idea
Last active November 27, 2016 17:14 — forked from grocky/idea
Open IDEA applications based on project type from the command line!
#!/usr/bin/env bash
IDEA=''
PROJECT_DIR=''
function main() {
openIdea "$@"
}
function openIdea() {