Skip to content

Instantly share code, notes, and snippets.

@bennadel
bennadel / assign.less
Created June 5, 2014 16:02
Executing JavaScript In The LESS CSS Precompiler
@foo: `javascript` ;
@dayfuaim
dayfuaim / git_files
Last active February 15, 2017 14:00
Get all files created/changed in the BRANCH
#!/bin/bash
#
# Usage: git_files <BRANCH>
#
# Get all files created/changed in the BRANCH
#
git diff --stat `git merge-base master $1`..$1
@jkbockstael
jkbockstael / AlbumsOrder.scpt
Created October 25, 2017 12:43
AppleScript to get iTunes to sort albums by release date
-- Fix albums display order
-- Changes the "sort album" field, to ensure that albums get displayed in chronological order on iPods.
-- CC-BY-NC 2011, Jean-Karim Bockstael,
tell application "iTunes"
-- input checking
if selection is {} then
display dialog "You must select at least a track"
return
else
set selected_tracks to selection
@AnwarShah
AnwarShah / gresource-extract
Created September 23, 2016 10:09
Gresource-extract. Original Credit goes to the author here http://projects.thecodergeek.com/scripts/gresource-extract
#!/bin/bash
##############################################################################
# Author: Peter Gordon <peter@thecodergeek.com>
# License: Public Domain
##############################################################################
# gresource-extract.sh
# Version: 1
#
# This Bash script is designed to extract all resource files in a given
# GResource file, with the given base folder. For example, if a GResource file
@kwcto
kwcto / mac-file-transfer-via-command-line.md
Created October 22, 2015 18:51
How to copy files / folders off a Mac from the command line (optionally using Single User Mode)
@alexbevi
alexbevi / redmine_view_hooks.md
Last active November 1, 2021 10:09
A list of the view hooks that are registered in Redmine

Redmine View Hooks

The following is a list of the registered view hooks available in Redmine, as of version 2.3.3.

These have been listed in the form of

:name_of_hook
path/to/file: { :param_1, :param_2, ... :param_n}
@tpai
tpai / instructions.md
Last active September 22, 2022 11:20
use both Tor and Privoxy with Mac OSX

1. install

brew install tor
brew install privoxy

2. copy and modify config file

@zmwangx
zmwangx / markdown-latex-etc.md
Last active March 5, 2023 09:47
An incomplete guide to Markdown, LaTeX, and more, initially written for Jiawen Li.

Markdown, LaTeX, etc.

Caution

  • (10/30/2016) I am not sure when and how this gist gained quite a few stars... But as stated in the v1.13 change log (from 06/16/2015): some content may be outdated, and I am not going to fix them. Moreover, having learned much myself, I do not necessarily agree with every point made in this document from 2.5 years ago. Therefore, please take views from this document with a grain of salt, and do further research as you see fit.

  • This document was initally written for a friend of mine, Jiawen Li, so it might reflect some personal tastes here and there. For instance, some discussions are geared towards Windows, though *nix is obviously superior. For another example, when I say "you seem to love Sublime Text a lot," I'm certainly not expecting most people to love Sublime (in fact I never used it for more than three minutes in a row).

  • This document is written in Markdown. The Markdown rendering engine on GitHub Gist is somewhat limited a

@Jamesits
Jamesits / MacType-James.ini
Last active March 27, 2023 10:15
My MacType profile, optimized for Telegram UWP and something else.
; Please see https://gist.github.com/Jamesits/6a58a1b08d5cd09a94a02f30ddaf0e13#gistcomment-2081294
; for instruction.
; Author: James Swineson <mactype@public.swineson.me>
[General]
Name=James Profile
; 【启用 DirectWrite 支持】
; [0:Disable] 1:Enable
DirectWrite=1
@mhawksey
mhawksey / gist:1276293
Last active October 23, 2023 09:00
Google App Script to insert data to a google spreadsheet via POST or GET - updated version as per https://mashe.hawksey.info/2014/07/google-sheets-as-a-database-insert-with-apps-script-using-postget-methods-with-ajax-example/
/*
Copyright 2011 Martin Hawksey
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software