Skip to content

Instantly share code, notes, and snippets.

[alias]
lg = log --max-count=100 --branches --color --graph --pretty=format:'%Cred%h%Creset - %C(bold blue)<%an>%Creset -%C(auto)%d%Creset %s %Cgreen(%cr)' --abbrev-commit
@DanKaplanSES
DanKaplanSES / git-m
Last active August 29, 2015 14:02
My Git Merge command
#!/bin/bash -x
set -e
#by naming this git-m and putting it in your PATH, git will be able to run it when you type "git m ..."
if [ "$#" -ne 2 ]
then
echo "Wrong number of arguments. Should be 2, was $#";
exit 1;
fi
@DanKaplanSES
DanKaplanSES / TechnicalPodcasts.md
Last active August 29, 2015 14:22
Technical Podcasts
"contraction <text> will":
R(Text("%(text)s'll ")),
"cap contraction <text> will":
R(Function(lambda text:Text(text.capitalize() + "'ll ").execute())),
"contraction <text> have":
R(Text("%(text)s've ")),
"cap contraction <text> have":
R(Function(lambda text:Text(text.capitalize() + "'ve ").execute())),
"contraction <text> are":
R(Text("%(text)s're ")),
@DanKaplanSES
DanKaplanSES / print_project.sh
Created August 23, 2023 02:29
A script to convert your current project into a stack overflow post
#! /usr/bin/bash
set -e
TREE_IGNORE_PATTERN='node_modules|tscbuild|package-lock.json|.gitignore|.git'
echo '### Project Structure'
echo '```'
tree --noreport -F -a -I $TREE_IGNORE_PATTERN | tr -d '*'
echo '```'
@DanKaplanSES
DanKaplanSES / list.md
Last active January 13, 2024 04:11
How do you start a markdown list at 10 or greater when the first element is multi-lined? (Click the "Raw" button to view source.)
  1. item

  2. item

    item

  3. item

  4. item

    This is some typescript code: