Skip to content

Instantly share code, notes, and snippets.

@smutao
smutao / appify
Created March 20, 2023 08:23 — forked from mathiasbynens/appify
appify — create the simplest possible Mac app from a shell script
#!/bin/bash
if [ "$1" = "-h" -o "$1" = "--help" -o -z "$1" ]; then cat <<EOF
appify v3.0.1 for Mac OS X - http://mths.be/appify
Creates the simplest possible Mac app from a shell script.
Appify takes a shell script as its first argument:
`basename "$0"` my-script.sh
@smutao
smutao / draw_hist_ascii.py
Last active July 30, 2022 22:03 — forked from bgbg/asciihist.py
Draw histogram in command line with Python
# draw histogram in command line with Python
# smutao@github, July 30, 2022
#
# usage: $ cat datafile.txt | python draw_hist_ascii.py [nbins] [nscale]
# The input should be one column of numbers to be piped in.
#
# forked from https://gist.github.com/bgbg
from __future__ import print_function
import sys