Skip to content

Instantly share code, notes, and snippets.

View dterracino's full-sized avatar
🐢
I may be slow to respond…

David Terracino dterracino

🐢
I may be slow to respond…
View GitHub Profile

Keybase proof

I hereby claim:

  • I am dterracino on github.
  • I am gamedrop (https://keybase.io/gamedrop) on keybase.
  • I have a public key whose fingerprint is 070A 3873 24DB 854B 11A8 2261 B5AC A056 05C8 58C8

To claim this, I am signing this object:

@dterracino
dterracino / passwordsafe-sync.md
Created March 28, 2016 00:39 — forked from Artanis/passwordsafe-sync.md
Build a syncronized password store using PasswordSafe and Google Drive, Dropbox, or Box.
@dterracino
dterracino / GameOfLife.cs
Created May 16, 2016 21:22 — forked from joelmartinez/GameOfLife.cs
Conway's Game Of Life in C#
using System;
using System.Threading.Tasks;
namespace Life
{
public class LifeSimulation
{
private bool[,] world;
private bool[,] nextGeneration;
private Task processTask;
@dterracino
dterracino / SlackClient.cs
Created July 13, 2016 05:41 — forked from jogleasonjr/SlackClient.cs
A simple C# class to post messages to a Slack channel. You must have the Incoming WebHooks Integration enabled. This class uses the Newtonsoft Json.NET serializer available via NuGet. Scroll down for an example test method and a LinqPad snippet. Enjoy!
using Newtonsoft.Json;
using System;
using System.Collections.Specialized;
using System.Net;
using System.Text;
//A simple C# class to post messages to a Slack channel
//Note: This class uses the Newtonsoft Json.NET serializer available via NuGet
public class SlackClient
{
@dterracino
dterracino / FNAWindowExample.cs
Created September 30, 2016 03:15 — forked from flibitijibibo/FNAWindowExample.cs
Example to hook up an SDL2 window to a Panel for use in a System.Windows.Forms window
#region License
/* FNA GameWindow for System.Windows.Forms Example
* Written by Ethan "flibitijibibo" Lee
* http://www.flibitijibibo.com/
*
* Released under public domain.
* No warranty implied; use at your own risk.
*/
#endregion
@dterracino
dterracino / .gitignore
Created March 30, 2017 00:59 — forked from arlm/.gitignore
Prime numbers IEnumerable in C#
bin
obj
@dterracino
dterracino / ConsoleAppMainAsync.cs
Created March 30, 2017 20:44 — forked from dkudelko/ConsoleAppMainAsync.cs
async console applicatiion main
class Program
{
static void Main(string[] args)
{
CancellationTokenSource cts = new CancellationTokenSource();
Console.CancelKeyPress += (s, e) =>
{
e.Cancel = true;
cts.Cancel();
};
@dterracino
dterracino / ShortGuid.cs
Created April 15, 2017 09:17 — forked from 06b/ShortGuid.cs
ShortGuid - A shorter and url friendly GUID class in C#
using System;
namespace CSharpVitamins
{
/// <summary>
/// Represents a globally unique identifier (GUID) with a
/// shorter string value. Sguid
/// </summary>
public struct ShortGuid
{
@dterracino
dterracino / ErrorController.cs
Created April 15, 2017 09:18 — forked from 06b/ErrorController.cs
ASP.NET MVC CustomErrors
public class ErrorController : Controller
{
// GET: Error
public ActionResult Index()
{
//Deal with aspxerrorpath
if (!string.IsNullOrEmpty(Request.QueryString["aspxerrorpath"]))
{
return RedirectToAction("Index");
}
// ************** Implementation **************
namespace CodeDucky
{
using Microsoft.CSharp.RuntimeBinder;
using System;
using System.Collections;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;