Skip to content

Instantly share code, notes, and snippets.

View jameswilson's full-sized avatar

James Wilson jameswilson

View GitHub Profile
@Jach
Jach / mig.py
Created December 30, 2011 04:09
Dirty migration script from Jira issues to Github issues
'''
Steps:
1. Create any milestones
2. Create any labels
3. Create each issue, linking them to milestones and labels
3.1: Update status for new issue if closed
4: Create all the comments for each issue
'''
import getpass
import json
@axelav
axelav / gist:1839777
Created February 15, 2012 22:51 — forked from lucasfais/gist:1207002
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
@ry5n
ry5n / sass-input-placeholders
Created March 13, 2012 07:06
CSS3 Input Placeholders using Sass 3.2
// Handle browser inconsistencies with placeholder pseudo-elements.
@mixin placeholders {
&::-webkit-input-placeholder { @content; }
&:-moz-placeholder { @content; }
&::placeholder { @content; }
}
// Set the colour for input placeholder text.
@mixin placeholder($color: #bfbfbf) {
@include placeholders {
@jameswilson
jameswilson / QLColorCode-drupal.patch
Created May 12, 2012 15:38
Patch for Drupal QuickLook Syntax Highlighting with QLColorCode.qlgenerator
diff --git a/Contents/Info.plist b/Contents/Info.plist
index 30088e8..6516736 100644
--- a/Contents/Info.plist
+++ b/Contents/Info.plist
@@ -170,6 +170,8 @@
<key>public.filename-extension</key>
<array>
<string>ini</string>
+ <string>info</string>
+ <string>diz</string>
@jameswilson
jameswilson / QLColorCode-sass-less-compass.patch
Created May 12, 2012 16:19
Patch for SASS, LESS, Compass QuickLook Syntax Highlighting with QLColorCode.qlgenerator
diff --git a/Contents/Info.plist b/Contents/Info.plist
index 30088e8..1fba4c8 100644
--- a/Contents/Info.plist
+++ b/Contents/Info.plist
@@ -284,6 +284,9 @@
<key>public.filename-extension</key>
<array>
<string>css</string>
+ <string>less</string>
+ <string>scss</string>
@datagrok
datagrok / git-branch-simplify.md
Last active April 16, 2024 17:26
How to simplify the graph produced by git log --graph

Ideas for improvements to git log --graph

I will maybe someday get around to dusting off my C and making these changes myself unless someone else does it first.

Make the graph for --topo-order less wiggly

Imagine a long-running development branch periodically merges from master. The git log --graph --all --topo-order is not as simple as it could be, as of git version 1.7.10.4.

It doesn't seem like a big deal in this example, but when you're trying to follow the history trails in ASCII and you've got several different branches displayed at once, it gets difficult quickly.

@cimmanon
cimmanon / flexbox.scss
Last active September 17, 2020 15:05 — forked from anonymous/Flexbox mixins
This collection of Sass mixins to cover all 3 flexbox specifications that have been implemented. More information can be found here: https://gist.github.com/cimmanon/727c9d558b374d27c5b6
@import "compass/css3/shared";
// NOTE:
// All mixins for the 2009 spec have been written assuming they'll be fed property values that
// correspond to the standard spec. Some mixins can be fed values from the 2009 spec, but don't
// rely on it. The `legacy-order` mixin will increment the value fed to it because the 2009
// `box-ordinal-group` property begins indexing at 1, while the modern `order` property begins
// indexing at 0.
// if `true`, the 2009 properties will be emitted as part of the normal mixin call
@xavez
xavez / Gruntfile.js
Last active August 2, 2016 05:20
Grunt: Compass, Autoprefixer, CSS/JS minification and Livereload. Use the `npm install`and `grunt` commands consecutively to execute.
module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-compass');
grunt.loadNpmTasks('grunt-autoprefixer');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.initConfig({
@cimmanon
cimmanon / _flexbox.scss
Last active February 11, 2016 02:51
New Flexbox mixins (in progress)
// $flexbox-support values:
// standard: Draft #3
// modern: Draft #2 or newer
// legacy: Draft #1 only
// wrap: versions that support wrapping (includes feature query on the display property on the unprefixed standard value)
// all: all versions
$flexbox-support-threshold: $critical-usage-threshold !default;
$flexbox-support: modern !default;
$flexbox-warnings: true !default;
@jameswilson
jameswilson / columns.css
Created August 1, 2014 22:53
Columns based on number of siblings
/**
* Technique from http://lea.verou.me/2011/01/styling-children-based-on-their-number-with-css3/
*/
/* one item */
li:first-child:nth-last-child(1) {
width: 100%;
}
/* two items */