git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git
cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
| ## Pre-requisite: You have to know your last commit message from your deleted branch. | |
| git reflog | |
| # Search for message in the list | |
| # a901eda HEAD@{18}: commit: <last commit message> | |
| # Now you have two options, either checkout revision or HEAD | |
| git checkout a901eda | |
| # Or | |
| git checkout HEAD@{18} |
| using System; | |
| using System.Runtime.InteropServices; | |
| namespace ConsoleApplication2 | |
| { | |
| [StructLayout(LayoutKind.Explicit)] | |
| internal struct Barbeque | |
| { | |
| [FieldOffset(0)] public int Barbe; | |
| [FieldOffset(0)] public bool Que; |
| using System; | |
| using System.Reflection; | |
| class Program | |
| { | |
| static void Main(string[] args) | |
| { | |
| var allocate = typeof(RuntimeTypeHandle).GetMethod("Allocate", BindingFlags.NonPublic | BindingFlags.Static); | |
| var math = allocate.Invoke(null, new[] { typeof (Math) }); |
git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git
cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
| using System; | |
| using System.CodeDom.Compiler; | |
| using System.Collections.Generic; | |
| using System.Diagnostics; | |
| using System.Reflection; | |
| using System.Text; | |
| using Microsoft.CSharp; | |
| namespace ActiveMesa.R2P.Infrastructure | |
| { |