- Fork https://github.com/github/dmca
- Download latest youtube-dl source code from https://yt-dl.org/latest
- Extract
tar -xvf youtube-dl-2020.09.20.tar.gz
- Push code to your fork as the GitHub CEO
tar -xvf youtube-dl-2020.09.20.tar.gz
''' | |
Extract the static image and video from a motion picture taken with a Huawei phone | |
''' | |
import os | |
import sys | |
from optparse import OptionParser |
// simple benchmark for reversing a string in js - source https://medium.com/quick-code/5-ways-to-reverse-a-string-in-javascript-466f62845827 | |
function reverseFor(str){ | |
let reversed = ""; | |
for (var i = str.length - 1; i >= 0; i--){ | |
reversed += str[i]; | |
} | |
return reversed; | |
} | |
function reverseArray(str){ | |
return str.split("").reverse().join(""); |
console.hex = (d) => console.log((Object(d).buffer instanceof ArrayBuffer ? new Uint8Array(d.buffer) : | |
typeof d === 'string' ? (new TextEncoder('utf-8')).encode(d) : | |
new Uint8ClampedArray(d)).reduce((p, c, i, a) => p + (i % 16 === 0 ? i.toString(16).padStart(6, 0) + ' ' : ' ') + | |
c.toString(16).padStart(2, 0) + (i === a.length - 1 || i % 16 === 15 ? | |
' '.repeat((15 - i % 16) * 3) + Array.from(a).splice(i - i % 16, 16).reduce((r, v) => | |
r + (v > 31 && v < 127 || v > 159 ? String.fromCharCode(v) : '.'), ' ') + '\n' : ''), '')); |
# SSH Agent | |
# Note: ~/.ssh/environment should not be used, as it | |
# already has a different purpose in SSH. | |
# source : https://www.schoonology.com/technology/ssh-agent-windows/ | |
env=~/.ssh/agent.env | |
# Note: Don't bother checking SSH_AGENT_PID. It's not used | |
# by SSH itself, and it might even be incorrect | |
# (for example, when using agent-forwarding over SSH). |
#!/bin/bash | |
docker exec -t CONTAINER_NAME mongodump -out /backups/dump_`date "+%Y-%m-%d-%H-%M-%S"` |
#!/bin/bash | |
# Set up ssh-agent | |
SSH_ENV="$HOME/.ssh/environment" | |
function start_agent { | |
echo "Initializing new SSH agent..." | |
touch $SSH_ENV | |
chmod 600 "${SSH_ENV}" | |
/usr/bin/ssh-agent | sed 's/^echo/#echo/' >> "${SSH_ENV}" |
This snippet of code was posted in 2014 and slightly revised in 2016 and 2017. It was more of a quick'n'dirty script than a polished tool. It is made only for Linux and in Python 2, which has since become outdated.
I currently do not use it, and I suggest you avoid it as well. Please do not expect support for using this script.
🔥 If you need an alternative, @glaucocustodio has kindly suggested EasyVPN in this comment.
The rest of the README is left for historical purposed.
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.