Skip to content

Instantly share code, notes, and snippets.

@jacob-faber
jacob-faber / GitHub-Forking.md
Created June 28, 2021 15:28 — forked from Chaser324/GitHub-Forking.md
GitHub Standard Fork & Pull Request Workflow

Whether you're trying to give back to the open source community or collaborating on your own projects, knowing how to properly fork and generate pull requests is essential. Unfortunately, it's quite easy to make mistakes or not know what you should do when you're initially learning the process. I know that I certainly had considerable initial trouble with it, and I found a lot of the information on GitHub and around the internet to be rather piecemeal and incomplete - part of the process described here, another there, common hangups in a different place, and so on.

In an attempt to coallate this information for myself and others, this short tutorial is what I've found to be fairly standard procedure for creating a fork, doing your work, issuing a pull request, and merging that pull request back into the original project.

Creating a Fork

Just head over to the GitHub page and click the "Fork" button. It's just that simple. Once you've done that, you can use your favorite git client to clone your repo or j

@jacob-faber
jacob-faber / takeout-merge.sh
Created November 12, 2019 07:48
Google Takeout Merge Tool: Unzips and merges all your exported data into a single folder
#!/usr/bin/env bash
destDir="../Takeout-merge"
mkdir -p $destDir
# Merges the different unzipped Takeout folders into one
for p in $(seq -f "%03g" 1 ${1:-1}); do
if [ -f $p/DONE ]; then
echo "Skipping $p/Takeout ... "
@jacob-faber
jacob-faber / ip_firewall_filter.rsc
Created September 4, 2019 13:41 — forked from SmartFinn/ip_firewall_filter.rsc
MikroTik (RouterOS) Zone-Based Firewall Example
# jan/29/2018 22: 4:17 by RouterOS 6.41
#
/interface list
add name=public comment="public network"
add name=local comment="local network"
add name=guest comment="guest network"
# Change the interfaces below to your own
/interface list member
add list=public interface=ether1
@jacob-faber
jacob-faber / starttmux.sh
Created November 26, 2018 11:43 — forked from todgru/starttmux.sh
Start up tmux with custom windows, panes and applications running
#!/bin/sh
#
# Setup a work space called `work` with two windows
# first window has 3 panes.
# The first pane set at 65%, split horizontally, set to api root and running vim
# pane 2 is split at 25% and running redis-server
# pane 3 is set to api root and bash prompt.
# note: `api` aliased to `cd ~/path/to/work`
#
session="work"

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name:

@jacob-faber
jacob-faber / zsh.md
Created November 14, 2018 22:43 — forked from tsabat/zsh.md
Getting oh-my-zsh to work in Ubuntu
@jacob-faber
jacob-faber / openshift-cheatsheet.md
Created August 20, 2018 10:36 — forked from rafaeltuelho/openshift-cheatsheet.md
My Openshift Cheatsheet
  • Change Default response timeout for a specific route:
oc annotate route <route_name> --overwrite haproxy.router.openshift.io/timeout=10s
  • Add a nodeSelector on RC ou DC
oc patch dc|rc <dc_name> -p "spec:                                                                                         
  template:     
@jacob-faber
jacob-faber / switch-local-git-repo-to-fork.md
Created July 20, 2018 13:16 — forked from jpierson/switch-local-git-repo-to-fork.md
How to move to a fork after cloning

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)

@jacob-faber
jacob-faber / docker-cleanup-resources.md
Created July 13, 2018 07:07 — forked from bastman/docker-cleanup-resources.md
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm

@jacob-faber
jacob-faber / cheatsheet.md
Created August 22, 2017 06:45 — forked from hay/cheatsheet.md
Hay's dev cheatsheet