Skip to content

Instantly share code, notes, and snippets.

View piksel's full-sized avatar
📠

nils måsén piksel

📠
View GitHub Profile
@piksel
piksel / hitbox-dark
Last active August 29, 2015 14:05
darker theme for hitbox chat
jQuery:
$('head').append('<style>.chatBody li>div { color: #eee }.chat, .chat-table tr, .chat-table td { background: #333; }.name {text-shadow:0 0 3px #000} a {color: #A4DB00; }</style>')
css:
.chatBody li>div { color: #eee }.chat, .chat-table tr, .chat-table td { background: #333; }.name {text-shadow:0 0 3px #000} a {color: #A4DB00; }
@piksel
piksel / shellshock.sh
Created September 26, 2014 15:25
Shellshock test
echo -ne "\nShellshock: "; env x='() { :;}; echo -n not\ ' bash 2> /dev/null -c "echo patched"; bash --version | head -n1
private void CloseConnections(Action action)
{
panel2.Dock = DockStyle.Fill;
panel2.Visible = true;
new Thread(() =>
{
Log("Closing connections...");
foreach (TcpListener tl in tcpListeners)
{
Log("- Closing listening socket " + tl.LocalEndpoint.ToString());
@piksel
piksel / web.config.xml
Last active September 1, 2015 06:54
web.config for ember.js routing
<configuration>
<system.web>
<rewrite>
<rules>
<rule name="Ember.js routing" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
@piksel
piksel / svtplay-vlc.js
Created April 17, 2012 22:39
Greasemonkey script for adding links for watching SVTPlay in VLC and/or downloading
// ==UserScript==
// @name SvtPlay VLC Link
// @namespace http://piksel.se
// @version 0.2
// @description Adds links for watching in VLC and/or downloading
// @match http://*svtplay.se/t/*
// @copyright 2012+, Nils Måsén
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.js
// ==/UserScript==
@piksel
piksel / wimp_view.js
Created April 17, 2012 22:35
Greasemonkey script for nice full screen view of wimp.com
// ==UserScript==
// @name Wimp Viewer
// @namespace http://piksel.se
// @version 0.1
// @description enter something useful
// @match http://www.wimp.com/*/
// @copyright 2012+, Nils Måsén
// ==/UserScript==
setTimeout(function(){
@piksel
piksel / Handlebars.sublime-build
Created November 8, 2012 10:06
build system for handlebars compiling in sublime text 2
{
"selector": "source.handlebars",
"cmd": ["handlebars", "$file", "-f", "$file_path/../js/$file_base_name.handlebars.js"],
"windows": {
"cmd": ["handlebars.cmd", "$file", "-f", "$file_path/../js/$file_base_name.handlebars.js"]
},
"variants": [
{
@piksel
piksel / manifest.yaml
Last active December 11, 2015 16:37
Example manifest YAML for Hale Check
information:
name: My Check
version: 1.0
website: http://dev.nesc.io/my-check
author:
name: Nomen Nescio
company: NN inc.
email: nomen@nesc.io
website: http://nesc.io
@piksel
piksel / gist:5128208
Created March 10, 2013 11:19
/r/sublimetext css tabified
body {
background-color:#1d1f20;
color:#d0d2d2
}
#header {
background-image:url(http://d.thumbs.redditmedia.com/jGRlerR8rxRx4jp3.png);
background-repeat:repeat-x;
background-position:bottom left;
background-color:#383838;
border:none
echo "main(i){for(i=0;;i++)putchar(((i*(i>>8|i>>9)&46&i>>8))^(i&i>>13|i>>6));}" | gcc -x c - && ./a.out | aplay