Skip to content

Instantly share code, notes, and snippets.

View obar1's full-sized avatar
🏠
Working from home

mar10 obar1

🏠
Working from home
View GitHub Profile
@obar1
obar1 / youtube-ls-playlist.sh
Created September 10, 2017 18:31 — forked from zmwangx/youtube-ls-playlist.sh
List video URIs in a YouTube playlist.
#!/usr/bin/env bash
# Takes a YouTube URI to a playlist (fairly liberal, it's fine as long
# as the playlist id can be extracted), and prints a list of URIs in a
# YouTube playlist.
#
# Requires youtube-dl 2014.10.24, tested on youtube-dl
# 2014.11.02.1. Feature subject to change.
youtube-dl -j --flat-playlist "$1" | jq -r '.id' | sed 's_^_https://youtube.com/v/_'
@zentralwerkstatt
zentralwerkstatt / instructions.md
Last active July 5, 2021 18:58
SSH into Linux Subsystem for Windows
  • In /etc/ssh/sshd_conf, set UsePrivilegeSeparation to no
  • In /etc/ssh/sshd_conf, temporarily enable plaintext passwords
  • In /etc/ssh/sshd_conf, change port (e.g. to 23) to avoid confusion with Windows SSH server
  • sudo service ssh restart
  • Add alternative port as a new rule to Windows firewall
  • On the client: ssh-copy-id user@server
  • In /etc/ssh/sshd_conf, re-disable plaintext passwords

To fix Could not load host key ... error:

  • sudo ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key
@obar1
obar1 / mplayer extract
Created June 25, 2017 17:57
to extract images frome video
mplayer -vo null -ao null -frames 0 -identify "file.mpg"
// LOOK FOR id_length
//8000
mpayer -vo jpeg -sstep 5 -endpos 8000 -nosound "file.mpg"
@itod
itod / split_keyboards.md
Last active September 23, 2025 07:22
Every "split" mechanical keyboard currently being sold that I know of
@cipri7329
cipri7329 / zeppelin0.6-cloudera5.7.md
Last active January 29, 2021 03:38
Zeppelin notebook with Cloudera
wget -r --no-parent -A '*CHANGES*' http://ws.com
grep -E -o "\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,6}\b" hbase-0.98.6-cdh5.3.6.CHANGES.txt | sort | uniq -i -z | uniq
@fomightez
fomightez / remove blank lines regex.md
Last active March 10, 2025 15:35
remove all blank lines using regular expressions
@jbub
jbub / squash-commits.sh
Created June 12, 2013 15:31
git squash last two commits into one
git rebase --interactive HEAD~2
# we are going to squash c into b
pick b76d157 b
pick a931ac7 c
# squash c into b
pick b76d157 b
s a931ac7 c
@mbostock
mbostock / .block
Last active April 19, 2025 08:19
The Gist to Clone All Gists
license: gpl-3.0