Skip to content

Instantly share code, notes, and snippets.

View aebm's full-sized avatar

Alejandro E Brito Monedero aebm

View GitHub Profile
@aebm
aebm / gist:c95501fcccaadf56cd0076ce252a422f
Created September 29, 2021 13:55 — forked from trongthanh/gist:2779392
How to move a folder from one repo to another and keep its commit history
# source: http://st-on-it.blogspot.com/2010/01/how-to-move-folders-between-git.html
# First of all you need to have a clean clone of the source repository so we didn't screw the things up.
git clone git://server.com/my-repo1.git
# After that you need to do some preparations on the source repository, nuking all the entries except the folder you need to move. Use the following command
git filter-branch --subdirectory-filter your_dir -- -- all
# This will nuke all the other entries and their history, creating a clean git repository that contains only data and history from the directory you need. If you need to move several folders, you have to collect them in a single directory using the git mv command.
@aebm
aebm / lm_srecon19_resources.md
Created November 5, 2019 11:18 — forked from loganmeetsworld/lm_srecon19_resources.md
"Optimizing for Learning" talk resources from SRECon Americas 2019 (Brooklyn)

"Optimizing for Learning" Sources

Given at SRECon Americas 2019 (Brooklyn) by Logan McDonald

Resources from my research are presented in the order they are given in the talk. Here are my slides and all the art is by the amazing Emily Griffin. The resources are broken into the four sections of the talk:

Preparation

@aebm
aebm / tmux-cheatsheet.markdown
Created October 2, 2018 10:39 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@aebm
aebm / original.py
Last active August 29, 2015 14:05
Borra DMs
import json
import requests
from requests_oauthlib import OAuth1
# Poner esto en CAPS para no confundirlo con una variable local (por convencion)
consumer_key='<YOUR CONSUMER KEY HERE>'
consumer_secret='<YOUR CONSUMER SECRET HERE>'
access_token_key='<YOUR ACCESS TOKEN HERE>'
access_token_secret='<YOUR ACCESS TOKEN SECRET HERE>'