Skip to content

Instantly share code, notes, and snippets.

Bradley Davis bad884

  • Intuit
  • San Jose, California
Block or report user

Report or block bad884

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View set_up_remote_node.sh
#!/bin/bash
ssh-keygen -t rsa -b 4096 -C "bad884@me.com"
cat .ssh/id_rsa.pub
read -p "Press enter to continue after adding SSH to Github"
git clone git@github.com:bad884/dotfiles.git .dotfiles
python ~/.dotfiles/.config/symlink_dotfiles.py
source ~/.bashrc
@JasonMoho
JasonMoho / dbench.sh
Last active Oct 2, 2018
Ceph benchmarking scripts
View dbench.sh
for i in $(seq 0 1 9)
do
SIZE=$((2**$i))
HEADER="########### SIZE = $SIZE ###########"
SEP="#################################"
echo $HEADER >> outwdbench.txt 2>&1
for j in $(seq 0 1 4)
do
echo $SEP >> outwdbench.txt 2>&1
CMD="dd if=/dev/zero of=here bs=1M count=$SIZE oflag=direct"
View dnd.sh
#!/bin/bash
set -eou pipefail
# From https://heyfocus.com/enabling-do-not-disturb-mode and
# https://apple.stackexchange.com/questions/145487
if [[ $(defaults -currentHost read ~/Library/Preferences/ByHost/com.apple.notificationcenterui doNotDisturb) -eq 0 ]]; then
defaults -currentHost write ~/Library/Preferences/ByHost/com.apple.notificationcenterui doNotDisturb -boolean true
defaults -currentHost write ~/Library/Preferences/ByHost/com.apple.notificationcenterui doNotDisturbDate -date "`date -u +\"%Y-%m-%d %H:%M:%S +000\"`"
@NeoTheFox
NeoTheFox / kitty.conf
Last active Apr 22, 2019
kitty config with solarized dark theme
View kitty.conf
# vim:fileencoding=utf-8:ft=conf
# Font family. You can also specify different fonts for the
# bold/italic/bold-italic variants. By default they are derived automatically,
# by the OSes font system. Setting them manually is useful for font families
# that have many weight variants like Book, Medium, Thick, etc. For example:
# font_family Operator Mono Book
# bold_font Operator Mono Thick
# bold_italic_font Operator Mono Medium
font_family Hack
@noelbundick
noelbundick / LICENSE
Last active Jun 12, 2019
Solarized Dark for Bash on Windows
View LICENSE
MIT License
Copyright (c) 2018 Noel Bundick
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
@erikmchut
erikmchut / .inputrc
Created Mar 17, 2017
My .inputrc with both emacs + vim goodness
View .inputrc
# Use Unicode & do NOT use the "8bit hack" to input/output non-ASCII characters
set input-meta on
set output-meta on
set convert-meta off
# Ignore completion case
set completion-ignore-case On
set match-hidden-files Off
set bell-style visible
@jpierson
jpierson / switch-local-git-repo-to-fork.md
Last active Jun 10, 2019 — forked from jagregory/gist:710671
How to move to a fork after cloning
View switch-local-git-repo-to-fork.md

If you are like me you find yourself cloning a repo, making some proposed changes and then deciding to later contributing back using the GitHub Flow convention. Below is a set of instructions I've developed for myself on how to deal with this scenario and an explanation of why it matters based on jagregory's gist.

To follow GitHub flow you should really have created a fork initially as a public representation of the forked repository and the clone that instead. My understanding is that the typical setup would have your local repository pointing to your fork as origin and the original forked repository as upstream so that you can use these keywords in other git commands.

  1. Clone some repo (you've probably already done this step)

    git clone git@github...some-repo.git
View my-recommended-ionic-development-setup.md
@pandafulmanda
pandafulmanda / Python3 Virtualenv Setup.md
Last active Jun 16, 2019 — forked from akszydelko/Python3 Virtualenv Setup.md
Setting up and using Python3 Virtualenv on Mac
View Python3 Virtualenv Setup.md

Python3 Virtualenv Setup

Requirements
  • Python 3
  • Pip 3
$ brew install python3
@santisbon
santisbon / Update-branch.md
Last active Jun 19, 2019
Bring your feature branch up to date with master. Deploying from Git branches adds flexibility. Bring your branch up to date with master and deploy it to make sure everything works. If everything looks good the branch can be merged. Otherwise, you can deploy your master branch to return production to its stable state.
View Update-branch.md

Updating a feature branch

First we'll update your local master branch. Go to your local project and check out the branch you want to merge into (your local master branch)

$ git checkout master

Fetch the remote, bringing the branches and their commits from the remote repository. You can use the -p, --prune option to delete any remote-tracking references that no longer exist in the remote. Commits to master will be stored in a local branch, remotes/origin/master

You can’t perform that action at this time.