Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
Baby Yoda is my spirit animal

Berkeley Martinez BerkeleyTrue

💭
Baby Yoda is my spirit animal
View GitHub Profile
View event-handlers-with-parameters-bind-constructor.js
class MyComponent extends React.Component {
constructor() {
this.handleClick = this.handleClick.bind(this, 'Parameter');
}
handleClick(param, e) {
console.log('Parameter', param);
console.log('Event', e);
}
@BerkeleyTrue
BerkeleyTrue / np.sh
Created Apr 7, 2017 — forked from stevemao/np.sh
Publish node module
View np.sh
# npm publish with goodies
# prerequisites:
# `npm install -g trash conventional-recommended-bump conventional-changelog conventional-github-releaser conventional-commits-detector json`
# `np` with optional argument `patch`/`minor`/`major`/`<version>`
# defaults to conventional-recommended-bump
# and optional argument preset `angular`/ `jquery` ...
# defaults to conventional-commits-detector
np() {
travis status --no-interactive &&
trash node_modules &>/dev/null;
@BerkeleyTrue
BerkeleyTrue / restart_bluetooth.sh
Created Apr 9, 2016 — forked from nicolasembleton/restart_bluetooth.sh
Restart Bluetooth Daemon on Mac OS X without restarting
View restart_bluetooth.sh
#!/bin/bash
sudo kextunload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport
sudo kextload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport
@BerkeleyTrue
BerkeleyTrue / fetch-git-pr.bash
Created Oct 9, 2015 — forked from vojtajina/fetch-git-pr.bash
Bash script for fetching a pull request from github...
View fetch-git-pr.bash
# fetching a single pull request from github
# put it into ~/.profile or ~/.bashrc
function fetch_pr() {
PR=$1
BRANCH=$2
if [ -z $PR ]; then
echo "Missing pull request number"
return 1
fi
@BerkeleyTrue
BerkeleyTrue / rebase-merge.sh
Created Oct 9, 2015 — forked from jeffbcross/rebase-merge.sh
How angular merges PRs
View rebase-merge.sh
#See fetch_pr script https://gist.github.com/vojtajina/5538170
# fetch and checkout PR branch from "upstream" remote
fetch_pr 123
git fetch upstream
# Replay changes on top of master
git rebase upstream/master
# Replace upstream/master with this branch
git push upstream pr-123:master
View gist:da9e1e345c03b75d4b98
All times EST. Add your initials next to any slot you can take (preferably 2 - 4 hour consecutive slots), and in a few words what you plan to stream.
NOTE(berkeley) fork to edit just like a repo. Then ask Quincy to merge in changes
Thursday:
17:00 -
18:00 -
19:00 -
20:00 -
21:00 -
View folder-structure.md

Folder Structure

Motivations

  • Clear feature ownership
  • Module usage predictibility (refactoring, maintainence, you know what's shared, what's not, prevents accidental regressions, avoids huge directories of not-actually-reusable modules, etc)
View Contract Killer 3.md

Contract Killer

The popular open-source contract for web designers and developers by Stuff & Nonsense

  • Originally published: 23/12/2008
  • Revised date: 15/12/2013
  • Original post

You can’t perform that action at this time.