Skip to content

Instantly share code, notes, and snippets.

View littlemooon's full-sized avatar
🌙

fred wright littlemooon

🌙
View GitHub Profile
@mablack
mablack / DynamicContentScroller.jsx
Created February 5, 2014 02:47
A React component based on SimpleScroller from react-touch. This component has support for detecting when the scrollable content area has changed size, and will reconfigure the Scroller. The project I'm working on scrolls through a list of captioned images, and the SimpleScroller component would calculate the scrollable dimensions before all the…
/** @jsx React.DOM */
var React = require('react');
var ZyngaScroller = require('react-touch/lib/environment/ZyngaScroller');
var AnimatableContainer = require('react-touch/lib/primitives/AnimatableContainer');
var TouchableArea = require('react-touch/lib/primitives/TouchableArea');
var ANIMATABLE_CONTAINER_STYLE = {
bottom: 0,
@chrismccoy
chrismccoy / gitcheats.txt
Last active February 27, 2025 15:51
git cheats
# alias to edit commit messages without using rebase interactive
# example: git reword commithash message
reword = "!f() {\n GIT_SEQUENCE_EDITOR=\"sed -i 1s/^pick/reword/\" GIT_EDITOR=\"printf \\\"%s\\n\\\" \\\"$2\\\" >\" git rebase -i \"$1^\";\n git push -f;\n}; f"
# aliases to change a git repo from private to public, and public to private using gh-cli
alias gitpublic="gh repo edit --accept-visibility-change-consequences --visibility public"
alias gitprivate="gh repo edit --accept-visibility-change-consequences --visibility private"
# delete all your repos using gh-cli (please do not run this unless you want to delete all your repos)
gh repo list --limit 300 --json url -q '.[].url' | xargs -n1 gh repo delete --yes