Skip to content

Instantly share code, notes, and snippets.

Michael Sarchet msarchet

Block or report user

Report or block msarchet

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
msarchet / plexer.js
Created Jun 30, 2019
A Dexplexer example for working with orca on multiple port
View plexer.js
const dgram = require('dgram')
const PortMaps = require('./portmaps.json')
this.server = dgram.createSocket('udp4')
this.listener = dgram.createSocket('udp4')
this.listener.on('message', (msg, rinfo) => {
let parts = `${msg}`.split("M")
let maps = parts[0].split("")
msarchet / SelfServer.js
Last active Nov 2, 2016
A Javascript file that acts as both a nodejs webserver and the index.html for the site that it serves
View SelfServer.js
// <head>
// <title>Self Server</title>
// </head>
// <body>
// <h1>Explanation here:</h1>
// <script type='text/javascript'>
// var process = { env: { server: false } }
if (process.env.server) {
const http = require('http')
msarchet / Test.xaml
Created Jun 24, 2016
View Test.xaml
View index.html
<div ng-app='app' ng-strict-di>
msarchet / app.js
Last active Aug 29, 2015
Flannel. Extendable logging module for angular
View app.js
(function () {
function homeController(logger) {
logger.log('thing', 123, {
123: 123
logger.warn('thing', 123, {
123: 123
});'thing', 123, {
123: 123

Keybase proof

I hereby claim:

  • I am msarchet on github.
  • I am msarchet ( on keybase.
  • I have a public key whose fingerprint is DDD4 7FBD B89E 77D4 42C8 30DE A230 02A9 9BBF 2810

To claim this, I am signing this object:

msarchet / test.html
Created Feb 20, 2014
test angular template
View test.html
View Lazier_T.cs
using System;
namespace Sandbox
class Program
static void Main(string[] args)
// Annoying to have to check Value all the time
Console.WriteLine(Person.LazyPerson.Value == Person.LazyPerson.Value);
View controller.cs
public class LayoutController : ApiController
[Route("", Name = "Index")]
public async Task<HttpResponseMessage> LayoutHtml()
var path = HttpContext.Current.IsDebuggingEnabled
? HttpContext.Current.Server.MapPath("~/App/Views/Index.html")
: HttpContext.Current.Server.MapPath("~/App/View/Index_Release.html");
var file = await File.OpenText(path).ReadToEndAsync();
msarchet / BaseActionResult.cs
Last active Jan 2, 2016
Generic Inheritance
View BaseActionResult.cs
namespace Services.Core.HttpActionResult
using System.Web.Http;
using System.Net.Http;
using System.Threading.Tasks;
public abstract class BaseActionResult : IHttpActionResult
protected readonly HttpRequestMessage request;
protected readonly Task task;
You can’t perform that action at this time.