Skip to content

Instantly share code, notes, and snippets.

tonsky / user.keymap
Created Jun 4, 2014
LightTable keymap of Sublime shortcuts
View user.keymap
{ :+
{ :editor
{ "pmeta-/" [:toggle-comment-selection]
"ctrl-shift-up" [:editor.sublime.selectLinesUpward]
"ctrl-shift-down" [:editor.sublime.selectLinesDownward]
"pmeta-d" [:editor.sublime.selectNextOccurrence]
"ctrl-m" [:editor.sublime.goToBracket]
"ctrl-shift-m" [:editor.sublime.selectBetweenBrackets]
"shift-pmeta-space" [:editor.sublime.selectScope]
"ctrl-pmeta-up" [:editor.sublime.swapLineUp]
stefanhoth / build.gradle
Last active Mar 3, 2017
Simple plugin for build.gradle to instruct Jetbrains IDEA-based IDEs (IntelliJ, Android Studio) to download sources of the dependencies. More settings can be found here:
View build.gradle
// your code
apply from: "build-plugins/idea-gradle-sources.gradle"
jhankin / SOInsetLabel.h
Created Nov 5, 2012
UILabel subclass encapsulating interior shadow functionality
View SOInsetLabel.h
// SOInsetLabel.h
// Created by Joseph Hankin on 11/2/12.
// From code posted by Rob Mayoff.
// Copyright (c) 2012 Joseph Hankin. All rights reserved.
devisnik / build.gradle
Last active Sep 5, 2017
Shrink Guava using Gradle
View build.gradle
apply plugin: 'base'
buildscript {
repositories {
dependencies {
classpath 'net.sf.proguard:proguard-gradle:4.11'
sethrylan / checkstyle.gradle
Last active Dec 25, 2018
Code Quality Tasks for Android
View checkstyle.gradle
configurations {
repositories {
dependencies {
codequality ''
artem-zinnatullin / GradleWorkersPleaseStopTakingFocus.gradle
Created Jul 21, 2015
Prevent Gradle Workers from taking focus! #DevelopersLikeComfort
View GradleWorkersPleaseStopTakingFocus.gradle
// You can place it in the root build.gradle
allprojects {
tasks.withType(JavaForkOptions) {
// Forked processes like GradleWorkerMain for tests won't steal focus!
jvmArgs '-Djava.awt.headless=true'
View KtorApp.kt
package main
import com.zaxxer.hikari.HikariDataSource
import org.apache.ibatis.annotations.Insert
import org.apache.ibatis.annotations.Select
import org.apache.ibatis.mapping.Environment
import org.apache.ibatis.session.Configuration
import org.apache.ibatis.session.SqlSession
import org.apache.ibatis.session.SqlSessionFactory
import org.apache.ibatis.session.SqlSessionFactoryBuilder
cyrilmottier / _app_avelibRelease_res_values_config.xml
Last active Nov 20, 2020
Using the new Gradle-based Android build system: an example
View _app_avelibRelease_res_values_config.xml
<?xml version="1.0" encoding="utf-8"?>
<string name="config_app_name">AVélib</string>
<string name="config_authority"></string>
<string name="">XXX</string>
sergeycherepanov /
Last active Jan 5, 2021
Traefik Systemd Example with letsencrypt
# /etc/traefik/conf.d/
backend = "blog"
passHostHeader = true
entrypoints = ["https", "http"]
priority = 100
extractorfunc = "client.ip"
period = "10s"
shibukawa / build graphiviz as layout engine
Created Jan 22, 2013
Graphviz's "plain" output is good for layout engine. This command creates the simplest Graphviz binary on Mac. You can easy to bundle your own program. I will try to run on Windows or cross-compile. This build supports only following output formats: canon cmap cmapx cmapx_np dot eps fig gv imap imap_np ismap pic plain plain-ext pov ps ps2 svg sv…
View build graphiviz as layout engine
#! /bin/sh
./configure --enable-static --disable-shared --disable-ltdl --disable-swig --disable-sharp --disable-go --disable-guile --disable-io --disable-java --disable-lua --disable-perl --disable-php --disable-python --disable-r --disable-ruby --disable-tcl --without-pic --without-tclsh --without-x --without-wish --without-expat --without-xpm --without-z --without-Xaw --without-webp --without-rsvg --without-ghostscript --without-visio --without-pangocairo --without-lasi --without-glitz --without-freetype2 --without-fontconfig --without-gtk --without-ming --without-qt --without-quartz --without-glut --without-cgraph --without-libgd --without-gdk_pixbuf LDFLAGS="-mmacosx-version-min=10.6"