Skip to content

Instantly share code, notes, and snippets.

Working from home

Vincent vincentzhezhang

Working from home
  • Sydney
Block or report user

Report or block vincentzhezhang

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
ctags -R --fields=+l --languages=python --python-kinds=-iv -f ./tags $(python -c "import os, sys; print(' '.join('{}'.format(d) for d in sys.path if os.path.isdir(d)))")
vincentzhezhang / i2g.rb
Created Mar 10, 2017
iTerm2 color scheme to Gnome-Terminal color scheme converter
View i2g.rb
# Courtesy of Steven Harms at:
require 'nokogiri-plist'
# /apps/gnome-terminal/profiles/Default
# -> background_color
# -> bold_color
vincentzhezhang /
Created Oct 19, 2016
Find out how many colours are being used in your project
echo 'Uniq hex colors:'
egrep -oIR '#([a-f]|[A-F]|[0-9]){3}(([a-f]|[A-F]|[0-9]){3})?\b' . | cut -d':' -f2 | tr "[A-Z]" "[a-z]" | sort -u
echo 'Uniq rgba colors:'
egrep -oIR "rgba\\(\\s*(0|[1-9]\\d?|1\\d\\d?|2[0-4]\\d|25[0-5])\\s*,\\s*(0|[1-9]\\d?|1\\d\\d?|2[0-4]\\d|25[0-5])\\s*,\\s*(0|[1-9]\\d?|1\\d\\d?|2[0-4]\\d|25[0-5])\\s*,\\s*((0.[1-9])|[01])\\s*\\)" . | cut -d':' -f2 | tr "[A-Z]" "[a-z]" | sort -u
vincentzhezhang / theme.css
Created Jul 8, 2016
seashell custom css for JSON View Chrome extension
View theme.css
body {
white-space: pre;
font-family: "Lucida Console", Monaco, monospace;
font-size: 14px;
color: #e4c3a1;
background: #081a23;
.property {
color: #d76539;
vincentzhezhang /
Last active Apr 21, 2016
Remove the deprecated unnecessary css extension name from scss files
find . -type f -name '*.css.scss' -exec bash -c 'mv $1 $(dirname "$1")/$(basename "$1" .css.scss).scss' _ {} \;
vincentzhezhang /
Created Nov 9, 2015 — forked from denji/
Remove WebStorm; PhpStorm; PyCharm; RubyMine; AppCode; CLion, IntelliJ; 0xDBE10 settings and cli-links from Mac OSX

Quick uninstall JetBrains settings:

curl -sL | bash -s
View monkey_king_elector.rb
require 'minitest/autorun'
class MonkeyKingElector
def elect(n, m)
(1..n).to_a.tap { |x| x.delete_at(m % x.size - 1) while x.size > 1 }[0]
#!/usr/bin/env bash
rsync -rv --include '*/' --include '*.js' --exclude '*' --prune-empty-dirs Source/ Target/
vincentzhezhang /
Created Oct 9, 2015
Short snippet to get total tracks
#!/usr/bin/env bash
find ./* -newermt 2015-10-05 | grep xml | xargs grep '<track>' | wc -l
View .fonts.conf
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
Documented at
To check font mapping run the command at terminal
$ fc-match 'helvetica Neue'
You can’t perform that action at this time.