Skip to content

Instantly share code, notes, and snippets.


Will Sams WillSams

View GitHub Profile
billgeek / -Generic Repository Pattern in
Last active Apr 5, 2019
Generic Repository Pattern in VB.NET
View -Generic Repository Pattern in

Creating a Generic Repository Pattern (VB.NET)

The below example shows how to implement a Repository of objects in a generic fashion. (This is the VB.NET version of my previous GIST) This was adapted and simplified from this article:


The point of this code is to allow the generic access to any object type in the datastore without the need to define a repository for each object. It is important to note that, although the below examples should work as is, it is recommended to make use of a dependency injection framework as database connection limits are not considered.

alirobe / reclaimWindows10.ps1
Last active Oct 11, 2020
This Windows 10 Setup Script turns off a bunch of unnecessary Windows 10 telemetery, bloatware, & privacy things. Not guaranteed to catch everything. Review and tweak before running. Reboot after running. Scripts for reversing are included and commented. Fork of (different defaults). N.…
View reclaimWindows10.ps1
# Tweaked Win10 Initial Setup Script
# Primary Author: Disassembler <>
# Modified by: alirobe <> based on my personal preferences.
# Version: 2.20.2, 2018-09-14
# Primary Author Source:
# Tweaked Source:
# Tweak difference:
# @alirobe's version is a subset focused on safely disabling telemetry, some 'smart' features and 3rd party bloat ...
harry-cpp / Game1.cs
Created Dec 27, 2015
VSCode + MonoGame
View Game1.cs
class Game1 : Game
protected override void LoadContent()
var proc = new Process();
proc.StartInfo.FileName = "/bin/bash";
proc.StartInfo.Arguments = "-c \"wmctrl -r 'Terminal' -b add,below && wmctrl -r '" + Window.Title + "' -b add,above\"";
proc.StartInfo.UseShellExecute = false;
proc.Start ();
michaelkarrer81 /
Last active Jun 5, 2020
[Saltstack Cheat Sheet] #saltstack
# ============
# ============
# Run state.sls file on minion(s)
salt -G 'os:Ubuntu' state.apply ubuntu1401 # Formula file name without .sls at the end
salt -G 'os:Ubuntu' state.apply ubuntu1401 test=True # Test only (dryrun)
salt -G "minion_roles:ONLINE" state.apply execute_script_example pillar='{"single_instance_update": "aiat"}'
# Webhook state.sls example
adamcrown / Gemfile
Created Nov 5, 2015
A basic mailer API intended to be used as a contact form backend for a static site.
View Gemfile
source ''
gem 'rack'
gem 'mail'
gem 'puma'
michaelkarrer81 / git_tricks
Last active Jan 31, 2019
[GIT Installation and Configuration] Git installation and configuration options #git
View git_tricks
#!/usr/bin/env bash
# -----------------
# -----------------
Tatsh /
Last active Dec 16, 2016
Burn a CDI (not by me)
#!/usr/bin/env bash
set -o errexit
cdirip "$cdi_img" -cdrecord
while true; do
danawoodman /
Last active Jul 10, 2020
React Hello World Examples

React "Hello World" Examples

Below are a small collection of React examples to get anyone started using React. They progress from simpler to more complex/full featured.

They will hopefully get you over the initial learning curve of the hard parts of React (JSX, props vs. state, lifecycle events, etc).


You will want to create an index.html file and copy/paste the contents of 1-base.html and then create a scripts.js file and copy/paste the contents of one of the examples into it.

RicoP / gist:7357080
Last active May 1, 2019
NES Rescources
View gist:7357080
shadowmint / gist:6928668
Created Oct 11, 2013
SDL2 mixer example
View gist:6928668
import ctypes
import unittest
import time
import os.path
from sdl2 import *
from sdl2.sdlmixer import *
class MixerTests(unittest.TestCase):
You can’t perform that action at this time.