Skip to content

Instantly share code, notes, and snippets.

View PeterNerlich's full-sized avatar

Peter Nerlich PeterNerlich

View GitHub Profile
@jakobii
jakobii / HTTPServer.ps1
Last active May 4, 2024 14:02
A Basic Powershell Webserver
# You Should be able to Copy and Paste this into a powershell terminal and it should just work.
# To end the loop you have to kill the powershell terminal. ctrl-c wont work :/
# Http Server
$http = [System.Net.HttpListener]::new()
# Hostname and port to listen on
$http.Prefixes.Add("http://localhost:8080/")
This work, excluding the Arch Linux logo, is made available under CC0: https://creativecommons.org/publicdomain/zero/1.0/
@Nnubes256
Nnubes256 / baselea.js
Last active February 10, 2017 23:09
BaseLea implementation
// TODO:
// - Add input validation
// - Improve reliability of atob parsing
var TABLE = [
"Hi.","Hi?","Hi!","Lea.", // 0...4
"Lea?","Lea!","Bye.","Bye?", // 5...8
"Bye!","How.","How?","How!", // 9...B
"Why.","Why?","Why!","..." // C...F
];
@simlun
simlun / raspi-monitor
Last active June 9, 2024 15:15
Script to enable and disable the HDMI signal of the Raspberry PI
#!/bin/bash -e
# /usr/local/sbin/raspi-monitor
# Script to enable and disable the HDMI signal of the Raspberry PI
# Inspiration: http://www.raspberrypi.org/forums/viewtopic.php?t=16472&p=176258
CMD="$1"
function on {
/opt/vc/bin/tvservice --preferred
var Util = require('util');
var Https = require('https');
var Tls = require('tls');
/**
* HTTPS Agent for node.js HTTPS requests via a proxy.
* blog.vanamco.com/connecting-via-proxy-node-js/
*/
function HttpsProxyAgent(options)
{