Skip to content

Instantly share code, notes, and snippets.

View AndrewSav's full-sized avatar

Andrew Savinykh AndrewSav

View GitHub Profile
# First, you must get the previous commit sha, the one before the forced push:
## Hit through terminal
curl -u <username> https://api.github.com/repos/:owner/:repo/events
# Then you can create a branch from this sha:
## Hit through terminal
curl -u <github-username> -X POST -d '{"ref":"refs/heads/<new-branch-name>", "sha":"<sha-from-step-1>"}' https://api.github.com/repos/:owner/:repo/git/refs
<Query Kind="Program">
<NuGetReference>YamlDotNet</NuGetReference>
<Namespace>YamlDotNet.Serialization</Namespace>
<Namespace>YamlDotNet.Core</Namespace>
<Namespace>System.Security.Cryptography</Namespace>
<Namespace>System.Runtime.InteropServices</Namespace>
</Query>
void Main()
{