Skip to content

Instantly share code, notes, and snippets.

View pomeh's full-sized avatar

Romain Guerin pomeh

View GitHub Profile
@pomeh
pomeh / level-remote4.json
Last active June 13, 2024 11:53
remote4 - pull.js
{
"goalTreeString": "{\"branches\":{\"main\":{\"target\":\"C4\",\"id\":\"main\",\"remoteTrackingBranchID\":\"o/main\",\"localBranchesThatTrackThis\":null},\"o/main\":{\"target\":\"C3\",\"id\":\"o/main\",\"remoteTrackingBranchID\":null,\"localBranchesThatTrackThis\":[\"main\"]}},\"commits\":{\"C0\":{\"parents\":[],\"id\":\"C0\",\"rootCommit\":true},\"C1\":{\"parents\":[\"C0\"],\"id\":\"C1\"},\"C2\":{\"parents\":[\"C1\"],\"id\":\"C2\"},\"C3\":{\"parents\":[\"C1\"],\"id\":\"C3\"},\"C4\":{\"parents\":[\"C2\",\"C3\"],\"id\":\"C4\"}},\"HEAD\":{\"target\":\"main\",\"id\":\"HEAD\"},\"originTree\":{\"branches\":{\"main\":{\"target\":\"C3\",\"id\":\"main\",\"remoteTrackingBranchID\":null,\"localBranchesThatTrackThis\":null}},\"commits\":{\"C0\":{\"parents\":[],\"id\":\"C0\",\"rootCommit\":true},\"C1\":{\"parents\":[\"C0\"],\"id\":\"C1\"},\"C3\":{\"parents\":[\"C1\"],\"id\":\"C3\"}},\"HEAD\":{\"target\":\"main\",\"id\":\"HEAD\"}}}",
"solutionCommand": "git pull",
"startTree": "{\"branches\":{\"main\":{\"target\":\
@pomeh
pomeh / level-remote2.json
Last active June 13, 2024 11:53
remote2 - remoteBranches.js
{
"goalTreeString": "{\"branches\":{\"main\":{\"target\":\"C3\",\"id\":\"main\"},\"o/main\":{\"target\":\"C1\",\"id\":\"o/main\"}},\"commits\":{\"C0\":{\"parents\":[],\"id\":\"C0\",\"rootCommit\":true},\"C1\":{\"parents\":[\"C0\"],\"id\":\"C1\"},\"C3\":{\"parents\":[\"C1\"],\"id\":\"C3\"},\"C4\":{\"parents\":[\"C1\"],\"id\":\"C4\"}},\"HEAD\":{\"target\":\"C4\",\"id\":\"HEAD\"},\"originTree\":{\"branches\":{\"main\":{\"target\":\"C2\",\"id\":\"main\"}},\"commits\":{\"C0\":{\"parents\":[],\"id\":\"C0\",\"rootCommit\":true},\"C1\":{\"parents\":[\"C0\"],\"id\":\"C1\"},\"C2\":{\"parents\":[\"C1\"],\"id\":\"C2\"}},\"HEAD\":{\"target\":\"main\",\"id\":\"HEAD\"}}}",
"solutionCommand": "git commit;git checkout o/main;git commit",
"startTree": "{\"branches\":{\"main\":{\"target\":\"C1\",\"id\":\"main\"},\"o/main\":{\"target\":\"C1\",\"id\":\"o/main\"}},\"commits\":{\"C0\":{\"parents\":[],\"id\":\"C0\",\"rootCommit\":true},\"C1\":{\"parents\":[\"C0\"],\"id\":\"C1\"}},\"HEAD\":{\"target\":\"main\",\"id\":\"HEAD\"},
@pomeh
pomeh / level.json
Last active June 13, 2024 11:53
Multiples branches level for learngitbranching.js.org
{
"goalTreeString": "{\"branches\":{\"main\":{\"target\":\"C1\",\"id\":\"main\",\"remoteTrackingBranchID\":null},\"feat-auth\":{\"target\":\"C7\",\"id\":\"feat-auth\",\"remoteTrackingBranchID\":null},\"fix-cve42\":{\"target\":\"C3\",\"id\":\"fix-cve42\",\"remoteTrackingBranchID\":null},\"doc-ios\":{\"target\":\"C5\",\"id\":\"doc-ios\",\"remoteTrackingBranchID\":null}},\"commits\":{\"C0\":{\"parents\":[],\"id\":\"C0\",\"rootCommit\":true},\"C1\":{\"parents\":[\"C0\"],\"id\":\"C1\"},\"C2\":{\"parents\":[\"C1\"],\"id\":\"C2\"},\"C3\":{\"parents\":[\"C1\"],\"id\":\"C3\"},\"C4\":{\"parents\":[\"C1\"],\"id\":\"C4\"},\"C5\":{\"parents\":[\"C4\"],\"id\":\"C5\"},\"C6\":{\"parents\":[\"C2\"],\"id\":\"C6\"},\"C7\":{\"parents\":[\"C6\"],\"id\":\"C7\"}},\"tags\":{},\"HEAD\":{\"target\":\"feat-auth\",\"id\":\"HEAD\"}}",
"solutionCommand": "git branch fix-cve42 v2;git branch doc-ios v3;git switch -c feat-auth v1;git branch -d v1 v2 v3;git commit;",
"startTree": "{\"branches\":{\"main\":{\"target\":\"C1\",\"id\":\"main
@pomeh
pomeh / git.json
Created February 12, 2024 14:38
learngitbranching test
{
"goalTreeString": "%7B%22branches%22%3A%7B%22main%22%3A%7B%22target%22%3A%22C9%22%2C%22id%22%3A%22main%22%2C%22remoteTrackingBranchID%22%3Anull%7D%2C%221-feature%22%3A%7B%22target%22%3A%22C7%27%22%2C%22id%22%3A%221-feature%22%2C%22remoteTrackingBranchID%22%3Anull%7D%2C%222-fix%22%3A%7B%22target%22%3A%22C5%22%2C%22id%22%3A%222-fix%22%2C%22remoteTrackingBranchID%22%3Anull%7D%7D%2C%22commits%22%3A%7B%22C0%22%3A%7B%22parents%22%3A%5B%5D%2C%22id%22%3A%22C0%22%2C%22rootCommit%22%3Atrue%7D%2C%22C1%22%3A%7B%22parents%22%3A%5B%22C0%22%5D%2C%22id%22%3A%22C1%22%7D%2C%22C2%22%3A%7B%22parents%22%3A%5B%22C1%22%5D%2C%22id%22%3A%22C2%22%7D%2C%22C3%22%3A%7B%22parents%22%3A%5B%22C2%22%5D%2C%22id%22%3A%22C3%22%7D%2C%22C4%22%3A%7B%22parents%22%3A%5B%22C3%22%5D%2C%22id%22%3A%22C4%22%7D%2C%22C5%22%3A%7B%22parents%22%3A%5B%22C4%22%5D%2C%22id%22%3A%22C5%22%7D%2C%22C6%22%3A%7B%22parents%22%3A%5B%22C3%22%5D%2C%22id%22%3A%22C6%22%7D%2C%22C7%22%3A%7B%22parents%22%3A%5B%22C6%22%5D%2C%22id%22%3A%22C7%22%7D%2C%22C8%22%3A%7B%22parents%2
@pomeh
pomeh / README.md
Last active January 12, 2024 18:42
awesome-pokemongo
@pomeh
pomeh / gist:a42207f11c74b7e6d7a6
Created December 26, 2015 16:30 — forked from atcuno/gist:3425484ac5cce5298932
HowTo: Privacy & Security Conscious Browsing

The purpose of this document is to make recommendations on how to browse in a privacy and security conscious manner. This information is compiled from a number of sources, which are referenced throughout the document, as well as my own experiences with the described technologies.

I welcome contributions and comments on the information contained. Please see the How to Contribute section for information on contributing your own knowledge.

Table of Contents

@pomeh
pomeh / package.json
Created October 18, 2015 21:59 — forked from addyosmani/package.json
npm run-scripts boilerplate
{
"name": "my-app",
"version": "1.0.0",
"description": "My test app",
"main": "src/js/index.js",
"scripts": {
"jshint:dist": "src/js/*.js'",
"jshint": "npm run jshint:dist",
"jscs": "jscs src/*.js",
"browserify": "browserify -s Validating -o ./dist/js/build.js ./lib/index.js",
#!/bin/bash
function flask-boilerplate-tmux
{
# https://github.com/swaroopch/flask-boilerplate
BASE="$HOME/code/flask-boilerplate"
cd $BASE
tmux start-server
tmux new-session -d -s flaskboilerplate -n model
@pomeh
pomeh / Default (Windows).sublime-keymap
Created January 14, 2015 12:03
Sublime Text 3 config example for sublime_findDoc package
// see Sublime Text package findDoc at https://github.com/zckrs/sublime_findDoc
[
// multiple shortcuts => multiple website
// aka: search on Google
{
"keys": ["ctrl+k", "ctrl+g"],
"command": "find_doc_selection",
"args" : {"url" : "https://google.fr/#q=%s" }
},
@pomeh
pomeh / copy-to-clipboard.js
Created July 27, 2014 17:39
JavaScript copy to clipboard function
function copyToClipboard(value) {
var tbx = document.createElement('input')
document.body.appendChild(tbx);
tbx.value = value;
tbx.focus();
tbx.setSelectionRange(0, tbx.value.length);
document.execCommand("copy");
document.body.removeChild(tbx);
}