Skip to content

Instantly share code, notes, and snippets.

@bitwes
bitwes / sample_command_line.gd
Created November 28, 2015 19:09
Robust command line argument parsing in Godot
# Example of a script that can be run from the command line and parses out options. This is adapted
# from the Gut command line interface. The first 2 classes are not to be used directly, they are used
# by the Options class and can be ignored. Start reading after the Options class to get a feel for
# how it is used, then work backwards.
#
# This could be easily extracted out into a class itself, but in the interest of how it is being used
# I wanted it all in one file. It is yours to do with what you please, but if you make something out
# of it, I'd love to hear about it. I'm bitwes on godot forums, github, and bitbucket.
extends SceneTree
@rroblak
rroblak / README.md
Last active October 26, 2023 03:22
git diff image files on the command line, with color

This is a simple way to spot check that the modified image in your git index is the image you actually want without having to leave the command line.

Example: http://i.imgur.com/RUenUcM.png

Instructions

  1. Install git, ImageMagick, and jp2a via your favorite package manager.
  2. Put img-ascii-diff somewhere (e.g. ~/bin/img-ascii-diff).
  3. Put attributes in ~/.config/git/attributes.
  4. Modify ~/.gitconfig and add the lines below, pointing to wherever you put img-ascii-diff.
@gf3
gf3 / html5.vim
Created May 5, 2010 15:27 — forked from rcmachado/html5.vim
vim HTML5 Syntax File
" Vim syntax file
" Language: HTML (version 5)
" Maintainer: Rodrigo Machado <rcmachado@gmail.com>
" URL: http://rm.blog.br/vim/syntax/html.vim
" Last Change: 2009 Aug 19
" License: Public domain
" (but let me know if you liked it :) )
"
" Note: This file just adds the new tags from HTML 5
" and don't replace default html.vim syntax file