Skip to content

Instantly share code, notes, and snippets.

View jontwo's full-sized avatar

Jon Morris jontwo

View GitHub Profile
@yeesian
yeesian / gdal-driver-options.txt
Created August 10, 2016 22:02
GDAL Driver Options (pretty printed)
Driver: VRT/Virtual Raster
Driver: GTiff/GeoTIFF
COMPRESS <string-select>: possible values: NONE,LZW,PACKBITS,JPEG,CCITTRLE,CCITTFAX3,CCITTFAX4,DEFLATE,
PREDICTOR <int>: Predictor Type (1=default, 2=horizontal differencing, 3=floating point prediction)
DISCARD_LSB <string>: Number of least-significant bits to set to clear as a single value or comma-separated list of values for per-band values
JPEG_QUALITY <int>: JPEG quality 1-100
JPEGTABLESMODE <int>: Content of JPEGTABLES tag. 0=no JPEGTABLES tag, 1=Quantization tables only, 2=Huffman tables only, 3=Both
ZLEVEL <int>: DEFLATE compression level 1-9
NUM_THREADS <string>: Number of worker threads for compression. Can be set to ALL_CPUS
NBITS <int>: BITS for sub-byte files (1-7), sub-uint16 (9-15), sub-uint32 (17-31)
@ngocvantran
ngocvantran / MoqExtensions.cs
Last active November 13, 2021 17:46
Extension methods to quickly ignore arguments without repeating It.IsAny<>()
using System;
using System.Linq.Expressions;
using Moq.Language.Flow;
namespace Moq
{
public static class MoqExtensions
{
public static ISetup<T, TResult> SetupIgnoreArgs<T, TResult>(this Mock<T> mock,
Expression<Func<T, TResult>> expression)
@octocat
octocat / .gitignore
Created February 27, 2014 19:38
Some common .gitignore configurations
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
@crofty
crofty / leaflet-google.js
Created March 25, 2012 15:07
Leaflet plugin that enables the use of Google Map tiles - http://matchingnotes.com/using-google-map-tiles-with-leaflet
/*
* L.TileLayer is used for standard xyz-numbered tile layers.
*/
L.Google = L.Class.extend({
includes: L.Mixin.Events,
options: {
minZoom: 0,
maxZoom: 18,
tileSize: 256,
@justintv
justintv / .bashrc
Created August 17, 2009 00:53
Display git branch in bash prompt
# If you work with git, you've probably had that nagging sensation of not knowing what branch you are on. Worry no longer!
export PS1="\\w:\$(git branch 2>/dev/null | grep '^*' | colrm 1 2)\$ "
# This will change your prompt to display not only your working directory but also your current git branch, if you have one. Pretty nifty!
# ~/code/web:beta_directory$ git checkout master
# Switched to branch "master"
# ~/code/web:master$ git checkout beta_directory
# Switched to branch "beta_directory"