Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View Daniel15's full-sized avatar
💭
Busy

Daniel Lo Nigro Daniel15

💭
Busy
View GitHub Profile
import sys
import extract_icon
import os
import argparse
class MorIcons:
"""
parses an ``APPS.INF`` file, dumps all icons from a PE binary and
generates an HTML file with all the icons and associated program
names
@iamarcel
iamarcel / Structuring Neat .NET Core Command Line Apps Neatly.org
Created September 7, 2016 07:30
Structuring Neat .NET Core Command Line Apps Neatly
@bevacqua
bevacqua / gulp-npm-publish.js
Created January 18, 2014 16:22
Publish packages to `npm` using Gulp.
var spawn = require('child_process').spawn;
gulp.task('npm', function (done) {
spawn('npm', ['publish'], { stdio: 'inherit' }).on('close', done);
});
@prabirshrestha
prabirshrestha / Bootstrapper.cs
Last active March 31, 2018 16:57
Server side reactjs rendering in Nancy with React.NET
public class Bootstrapper : DefaultNancyBootstrapper
{
protected override void RequestStartup(TinyIoCContainer container, IPipelines pipelines, NancyContext context)
{
base.RequestStartup(container, pipelines, context);
var react = new ReactEnvironment(
new JavaScriptEngineFactory(),
new ReactSiteConfiguration(),
new NullReactCache(),
/**
* Copyright 2013 Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@adammw
adammw / facebook-anonymiser.js
Last active August 29, 2015 14:06
Remove names from Facebook posts and comments allow them to be screenshotted and posted to internet forums without exposing user identities.
(function() {
var hash = {};
var anonymise = function() {
// Handle links to user profiles, e.g. those shown when someone likes a post
Array.prototype.forEach.call(document.querySelectorAll('[data-hovercard*="user.php"], [data-hovercard*="hovercard.php"]'), function(hovercardLink) {
if (!hovercardLink.dataset.hovercard) return;
var id = /id=(\d+)/.exec(hovercardLink.dataset.hovercard)[1];
var hue = hash[id] = hash[id] || (Math.random() * 360);
hovercardLink.style.background = 'hsl(' + hue + ',55%,60%)';