Skip to content

Instantly share code, notes, and snippets.

David De Sloovere DavidDeSloovere

Block or report user

Report or block DavidDeSloovere

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
blowdart / UpdateIISExpressSSLForChome.ps1
Last active Sep 21, 2019
IIS Express certs (for now) don't contain SAN strings. This makes Chrome unhappy. Make Chrome happy again with a new organic, artisanal, gluten free HTTPS certificate.
View UpdateIISExpressSSLForChome.ps1
# Create a new self signed HTTPS Certificate for IIS Express
# Crafted with all organic, GMO, gluten free ingreditations
# with an artisinal SAN to make Chrome 58 onwards happy.
# See
# Run this at an administrative PowerShell prompt.
# You will be prompted to trust a new certificate via a windows dialog.
# Click yes otherwise Visual Studio will not be able to determine your
pohatu / md2html.ps1
Created Jul 1, 2013
Use the GitHub markdown service to convert md to html via powershell.
View md2html.ps1
[CmdletBinding()] Param (
[Parameter(Position = 0, Mandatory = $True, ValueFromPipelineByPropertyName = $True)]
function ConvertFrom-md($mdText){
$response = Invoke-WebRequest -Uri '' -Method Post -body "$mdText" -ContentType "text/plain"
jbtule / AESGCM.cs
Last active Sep 10, 2019
I have two code examples that I wrote for best practices encrypting a string in c#. They are both using authenticated encryption.
View AESGCM.cs
* This work (Modern Encryption of a String C#, by James Tuley),
* identified by James Tuley, is free of known copyright restrictions.
using System;
using System.IO;
using System.Text;
xavierdecoster / register a myget feed.markdown
Last active Aug 30, 2018
Store MyGet credentials in your roaming user profile NuGet.config
View register a myget feed.markdown

Execute the following script using your MyGet [feedUrl] and MyGet [username] , [password] and [apikey]. Run this from a commandline where you have access to nuget.exe (or set the path to your nuget.exe in a system environment variable).

Store credentials in machine-level nuget.config (non-transferable)

nuget setapikey [apikey] -source [feedUrl]
nuget sources add|update -Name [name] -source [feedUrl] -User [username] -pass [password]
DanTup / VS References Yuml.ps1
Last active Oct 4, 2015
Output Visual Studio project references for
View VS References Yuml.ps1
function Get-ProjectReferences
dir $rootFolder -Filter *.csproj -Recurse |
rdingwall / Global.asax.cs
Created Mar 10, 2012
camelCase + indented JSON formatter for ASP.NET Web API
View Global.asax.cs
var config = GlobalConfiguration.Configuration;
// Replace the default JsonFormatter with our custom one
var index = config.Formatters.IndexOf(config.Formatters.JsonFormatter);
config.Formatters[index] = new JsonCamelCaseFormatter();
DavidDeSloovere / gist:1893621
Created Feb 23, 2012
Sample CacheAttribute for ASP.NET Web Api - i'm not saying this is the best way
View gist:1893621
namespace ProjectName.WebApi.Infrastructure
using System;
using System.Net;
using System.Net.Http.Headers;
using System.Web.Http.Filters;
public class CacheAttribute : ActionFilterAttribute
public CacheAttribute()
joshuaflanagan / nuget_tool.bat
Created Jun 24, 2011
Example batch file to execute a tool from a Nuget package
View nuget_tool.bat
REM This can be used for any .exe installed by a nuget package
REM Example usage: nuget_tool.bat nunit-console.exe myproject.tests.dll
FOR /R %~dp0\source\packages %%G IN (%TOOL%) DO (
joelnet / example.html
Created Jun 3, 2011
Unobtrusive Knockout support library for jQuery
View example.html
Choose a ticket class: <select id="tickets"></select>
<p id="ticketOutput"></p>
<script id="ticketTemplate" type="text/x-jquery-tmpl">
{{if chosenTicket}}
You have chosen <b>${ chosenTicket().name }</b>
($${ chosenTicket().price })
<button data-bind="click: resetTicket">Clear</button>
You can’t perform that action at this time.