Skip to content

Instantly share code, notes, and snippets.

View sibach's full-sized avatar

Steve Ibach sibach

View GitHub Profile
@kwmiebach
kwmiebach / pytest.md
Last active April 22, 2024 19:33 — forked from amatellanes/pytest.sh
pytest cheat sheet

Usage

(Create a symlink pytest for py.test)

pytest [options] [file_or_dir] [file_or_dir] ...

Help:

@miawgogo
miawgogo / README.md
Last active April 22, 2021 15:10 — forked from roelentless/README.md
Countdown. REVISED EDITION!!!!

Countdown. REVISED EDITION!!!!

This is a fork of ruleb's count down that rended one of the else ifs unreachable in his code. Even though he was notified by menny people he never fixed his code so i took it on to... fix 1 line of code. This Fork may expand if i have the time to re-learn coffie and see if any outher code is broken.

The rest of this readme and the html code and scss is still the orginal by ruleb.

Description

Simple Dashing widget to countdown until a certain moment. Flashes the widget when finished.

@ttscoff
ttscoff / ifttt-pocket_to_nvalt.rb
Created November 1, 2013 12:05
A Hazel script for converting IFTTT-saved Pocket favorites to nvALT notes
#!/usr/bin/env ruby
# Works with IFTTT recipe https://ifttt.com/recipes/125999
#
# Set Hazel to watch the folder you specify in the recipe.
# Make sure nvALT is set to store its notes as individual files.
# Edit the $target_folder variable below to point to your nvALT
# ntoes folder.
require 'date'
require 'open-uri'
require 'net/http'
@agnoster
agnoster / README.md
Last active April 6, 2024 22:35
My ZSH Theme

agnoster.zsh-theme

A ZSH theme optimized for people who use:

  • Solarized
  • Git
  • Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)

For Mac users, I highly recommend iTerm 2 + Solarized Dark

@mitfik
mitfik / gist:3402722
Created August 20, 2012 09:50
LDAP CheatSheet
# Get info about all Contexts in ldap
ldapsearch -x -H ldap://localhost -b "" -s base configContext namingContexts monitorContext
# display cn=config structures and data
ldapsearch -Y EXTERNAL -H ldapi:/// -b "cn=config"
# or
slapcat -b cn=config > config.ldiff
# modify config
@kisom
kisom / example.txt
Created July 31, 2012 18:57
Python command line utility to determine whether a site supports HSTS.
<monalisa: ~> $ has_hsts.py duckduckgo.com google.com search.google.com conformal.com yahoo.com lobste.rs news.ycombinator.com reddit.com
[+] checking whether duckduckgo.com supports HSTS... no
[+] checking whether google.com supports HSTS... no
[+] checking whether search.google.com supports HSTS... no
[+] checking whether conformal.com supports HSTS... yes
[+] checking whether yahoo.com supports HSTS... no
[+] checking whether lobste.rs supports HSTS... yes
[+] checking whether news.ycombinator.com supports HSTS... no
[+] checking whether reddit.com supports HSTS... doesn't have SSL working properly (hostname 'reddit.com' doesn't match either of 'a248.e.akamai.net', '*.akamaihd.net', '*.akamaihd-staging.net')
@mikeyk
mikeyk / gist:1329319
Created October 31, 2011 22:56
Testing storage of millions of keys in Redis
#! /usr/bin/env python
import redis
import random
import pylibmc
import sys
r = redis.Redis(host = 'localhost', port = 6389)
mc = pylibmc.Client(['localhost:11222'])
@btompkins
btompkins / Fabric-UserSetup.py
Created February 7, 2011 18:15
Simple fabric function to create a new user
def new_user(admin_username, admin_password):
env.user = 'root'
# Create the admin group and add it to the sudoers file
admin_group = 'admin'
runcmd('addgroup {group}'.format(group=admin_group))
runcmd('echo "%{group} ALL=(ALL) ALL" >> /etc/sudoers'.format(
group=admin_group))
# Create the new admin user (default group=username); add to admin group