Skip to content

Instantly share code, notes, and snippets.

Steely Wing steelywing

Block or report user

Report or block steelywing

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@steelywing
steelywing / couns.md
Last active Dec 14, 2016
Couns Door Setup
View couns.md

Default Mode

  • Access door
    • Input password (Default 1234)
    • Press #
  • Enter programming mode
    • Press *
    • Input admin password (Default 9999)
    • Press #
  • Exit programming mode and Save
    • Press * in 1 minute
View foobar-playlist-style.txt
//--VAR
$puts(brd,28-28-28)
$puts(brd2,70-70-70)
$puts(brd_g1,50-50-50)
$puts(brd_g2,35-35-35)
$puts(transparent, 0-0-0-0)
// Column padding
$puts(padding, 16)
@steelywing
steelywing / hosts.bat
Last active Oct 28, 2015
add host entry to windows hosts, run as administrator
View hosts.bat
@echo off
set hosts_file=%WINDIR%\System32\drivers\etc\hosts
set host=127.0.0.1 fvc_stat.freemake.com
find /i "%host%" %hosts_file% > nul
if %ERRORLEVEL% == 0 (
echo "%host%" already exist.
) else (
(echo. & echo %host%) >> %hosts_file%
@steelywing
steelywing / putty-serial.nsi
Last active Aug 29, 2015
Auto detect serial port to execute putty
View putty-serial.nsi
# Wrap putty-serial.vbs to exe
Name "PuTTY Serial"
Icon "putty.ico"
OutFile "putty-serial.exe"
InstallDir "$TEMP"
RequestExecutionLevel user
SilentInstall silent
Section
@steelywing
steelywing / ldap_escape.php
Created Apr 7, 2015
ldap_escape replacement for < PHP 5.6
View ldap_escape.php
// Source: http://stackoverflow.com/questions/8560874/php-ldap-add-function-to-escape-ldap-special-characters-in-dn-syntax#answer-8561604
if (!function_exists('ldap_escape')) {
define('LDAP_ESCAPE_FILTER', 0x01);
define('LDAP_ESCAPE_DN', 0x02);
/**
* @param string $subject The subject string
* @param string $ignore Set of characters to leave untouched
* @param int $flags Any combination of LDAP_ESCAPE_* flags to indicate the
@steelywing
steelywing / gpsd.md
Last active Aug 29, 2015
gpsd build build from source (CentOS 6.5)
View gpsd.md

Install

  • Download and extract
  • Refer INSTALL and build.txt in gpsd source
  • yum install gcc
  • yum install ncurses ncurses-devel
  • yum install python-devel
  • Install scons
  • Run scons in gpsd source folder
  • Run scons check
  • Run scons install
@steelywing
steelywing / Mcrypt.php
Last active Aug 29, 2015
php mcrypt class
View Mcrypt.php
<?php
class Mcrypt
{
/**
* @var string Encryption key
*/
public $key;
View linux.md

Network

Obsolete command

  • ifconfig => ip addr and ip link
  • netstat => ss, ip route

Set interface up on boot

/etc/sysconfig/network

NETWORKING=yes
@steelywing
steelywing / service.py
Created Aug 6, 2014
python windows service
View service.py
import win32serviceutil
import win32service
import win32event
import servicemanager
# import signal
# import os
from multiprocessing import Process
from main import app
You can’t perform that action at this time.