refactor publish functions.
refactor publish method to include more possibilities.
use basename of files instead of full names in create_gist.
collate publish.R and bump version.