Skip to content

Instantly share code, notes, and snippets.

View nachoesmite's full-sized avatar

Ignacio Esmite nachoesmite

  • pinarlabs
  • Costa de Oro, Uruguay
View GitHub Profile
@nachoesmite
nachoesmite / gist:3f367d6f4a96a4a9da523efef6374665
Last active March 2, 2018 20:36 — forked from msrose/combining-git-repositories.md
How to combine two git repositories.

Combining two git repositories

Use case: You have repository A with remote location rA, and repository B (which may or may not have remote location rB). You want to do one of two things:

  • preserve all commits of both repositories, but replace everything from A with the contents of B, and use rA as your remote location
  • actually combine the two repositories, as if they are two branches that you want to merge, using rA as the remote location

NB: Check out git subtree/git submodule and this Stack Overflow question before going through the steps below. This gist is just a record of how I solved this problem on my own one day.

Before starting, make sure your local and remote repositories are up-to-date with all changes you need. The following steps use the general idea of changing the remote origin and renaming the local master branch of one of the repos in order to combine the two master branches.

@nachoesmite
nachoesmite / gitcheats.txt
Created February 22, 2018 14:56 — forked from chrismccoy/gitcheats.txt
git cheats
# shortform git commands
alias g='git'
# get a list of all commit messages for a repo
git log --pretty=format:'%s'
# find the nearest parent branch of the current git branch
git show-branch -a | grep '\*' | grep -v `git rev-parse --abbrev-ref HEAD` | head -n1 | sed 's/.*\[\(.*\)\].*/\1/' | sed 's/[\^~].*//'
# push changes to an empty git repository for the first time
@nachoesmite
nachoesmite / tester-questions.md
Created September 4, 2016 05:27 — forked from smariapena/tester-questions.md
Questions I Like To Ask Testers In Interviews

#Tester Questions

Interview Fodder - Thursday; July 28, 2016

###Style/Opinion/Purview

  • Do you have a smartphone, what’s your favorite app? How would you test it?
  • Tell me about your favorite bug that you found and reported.
  • What are the benefits of an exploratory approach to software testing? Downsides?
  • Where do test cases fit into your typical project lifecycle in an agile project in the client services world?