Skip to content

Instantly share code, notes, and snippets.

View nelsonjchen's full-sized avatar

Nelson Chen nelsonjchen

View GitHub Profile
@techtonik
techtonik / NonBlockingPipe.md
Last active September 21, 2023 18:01
Non-blocking pipe reads in Windows Python
@gregjhogan
gregjhogan / PPPoE-info.sh
Created October 9, 2015 05:09
Retrieve CenturyLink PPPoE username/password from technicolor C2000T
# first enable telnet, and connect
# then you will get a '>' prompt where you want to run the following commands
sh
pidstat -l -C pppd
# see -u (username) and -p (password) in the output
@mirajavora
mirajavora / cloudformation-aws-elasticsearch.json
Last active April 4, 2021 15:20
Elastic Search AWS Cloudformation Script
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Description" : "Creates auto scaling Elastic Search Cluster",
"Parameters" : {
"InstanceType" : {
"Description" : "Elastic Search node instance type",
"Type" : "String",
"Default" : "t2.small",
@bitjockey42
bitjockey42 / install.md
Created August 7, 2015 19:40
Install SIP and PyQT4 (pyenv, pyenv-virtualenv)

Download

pyenv virtualenv

Switch to the Python version you want to use:

@Manouchehri
Manouchehri / windows10qemu.sh
Last active February 10, 2022 18:50
Running Windows 10 in a UEFI enabled QEMU environment with KVM.
# Installing
qemu-system-x86_64 -bios /usr/share/ovmf/ovmf_x64.bin -enable-kvm -cpu host -smp 4 -m 2048 -cdrom ~/Downloads/Win10_English_x64.iso -net nic,model=virtio -net user -drive file=~/vm/win10.hd.img.raw,format=raw,if=virtio -vga qxl -drive file=~/Downloads/virtio-win-0.1.105.iso,index=1,media=cdrom
# Running
qemu-system-x86_64 -bios /usr/share/ovmf/ovmf_x64.bin -enable-kvm -cpu host -smp 4 -m 4096 -net nic,model=virtio -net user -drive file=~/vm/win10.hd.img.raw,format=raw,if=virtio -vga qxl -usbdevice tablet -rtc base=utc
@AArnott
AArnott / ConsoleApp.csproj
Last active March 9, 2023 11:10
Async named pipes example
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>exe</OutputType>
<TargetFrameworks>net472;net5.0-windows</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="System.IO.Pipes.AccessControl" Version="5.0.0" />
</ItemGroup>

Live Transcoding

This is a collection of working commandline examples to show how one could use FFMpeg and VLC for live transcoding of video streams. All examples have been tested on OSX 10.7.5 with FFMPeg 1.1.3 and VLC 2.0.5 in early 2013.

Documentation links

@skarllot
skarllot / pdf-text-replace.sh
Created May 22, 2015 19:44
Replace text into PDF files
# CAM-PDF install
cpan
> install CAM::PDF
# Replace text
changepagestring.pl -o -v input.pdf srctext dsttext output.pdf
# Ref: http://search.cpan.org/dist/CAM-PDF/bin/changepagestring.pl
From f5908efac9f55216d5aabdee72687b2b47f1c89c Mon Sep 17 00:00:00 2001
From: Chang Liu <cliu712@aucklanduni.ac.nz>
Date: Mon, 13 Apr 2015 09:36:31 +0000
Subject: [PATCH] Add support for linux-musl in build system. Fix glibc
assumptions in code.
---
autoconf/config.sub | 7 +++++--
lib/ExecutionEngine/RuntimeDyld/RTDyldMemoryManager.cpp | 2 +-
lib/Support/DynamicLibrary.cpp | 4 ++--
@szepeviktor
szepeviktor / update-speedtest-mini.sh
Last active August 1, 2017 19:33
Check Speedtest Mini script's expiration and update it.
#!/bin/bash
#
# Check Speedtest Mini script's expiration and update it.
#
# DEPENDS :apt-get install swfmill html2text
# CRON-MONTHLY :/usr/local/bin/update-speedtest-mini.sh
##################
################## MOVED TO: https://github.com/szepeviktor/debian-server-tools/blob/master/monitoring/update-speedtest-mini.sh
##################