Skip to content

Instantly share code, notes, and snippets.

View rummik's full-sized avatar
💤
Sleeping to escape reality

*Kim Zick rummik

💤
Sleeping to escape reality
View GitHub Profile
// JS hooks for toggling style (think a wordy `$('.toggle-source a').click(function() { ... });`)
[].forEach.call(document.querySelectorAll('.toggle-source a'), function(element) {
element.onclick = function() {
document.body.className = this.getAttribute('id').replace('view-', '');
return false;
};
});
// a slightly Markdown parser
var xhr = new XMLHttpRequest();
@rummik
rummik / -
Created March 21, 2014 21:22
alias drop-caches='echo 3 | sudo tee /proc/sys/vm/drop_caches'
'hello world'
fusk.js: (1458 bytes)
(+(-~[]+[+[]]+[-~[]]))[([]+!![])[+[]]+([]+{})[-~[]]+(+[]+([]+{})[([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+{})[-~[]]+([]+{}[[]])[-~[]]+([]+![])[!![]-~[]-~[]]+([]+!![])[+[]]+([]+!![])[-~[]]+([]+{}[[]])[+[]]+([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+!![])[+[]]+([]+{})[-~[]]+([]+!![])[-~[]]])[-~[]+[+[]]]+([]+!![])[+[]]+([]+!![])[-~[]]+([![]]+{}[[]])[-~[]+[+[]]]+([]+{}[[]])[-~[]]+(+[]+[![]]+([]+{})[([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+{})[-~[]]+([]+{}[[]])[-~[]]+([]+![])[!![]-~[]-~[]]+([]+!![])[+[]]+([]+!![])[-~[]]+([]+{}[[]])[+[]]+([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+!![])[+[]]+([]+{})[-~[]]+([]+!![])[-~[]]])[!![]-~[]+[+[]]]](!![]-~[]+[-~[]])[-~[]]+([]+!![])[!![]-~[]-~[]]+([]+![])[!![]-~[]]+([]+![])[!![]-~[]]+([]+{})[-~[]]+([]+{})[+(-~[]+[+[]])+~[]+~[]+~[]]+(+(!![]-~[]-~[]+[!![]-~[]]))[([]+!![])[+[]]+([]+{})[-~[]]+(+[]+([]+{})[([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+{})[-~[]]+([]+{}[[]])[-~[]]+([]+![])[!![]-~[]-~[]]+([]+!![])[+[]]+([]+!![])[-~[]]+([]+{}[[]])[+[]]+([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+!![])[
@rummik
rummik / -
Created March 21, 2014 01:08
console.log((+(-~[]+([]+!![])[!![]-~[]-~[]]+-~[]+[+[]]+[+[]]+[+[]])+[])[+[]]+([]+{})[+(-~[]+[+[]])+~[]+~[]+~[]]+(+([!![]-~[]-~[]]+[!![]-~[]]))[([]+!![])[+[]]+([]+{})[-~[]]+(+[]+([]+{})[([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+{})[-~[]]+([]+{}[[]])[-~[]]+([]+![])[!![]-~[]-~[]]+([]+!![])[+[]]+([]+!![])[-~[]]+([]+{}[[]])[+[]]+([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+!![])[+[]]+([]+{})[-~[]]+([]+!![])[-~[]]])[-~[]+[+[]]]+([]+!![])[+[]]+([]+!![])[-~[]]+([![]]+{}[[]])[-~[]+[+[]]]+([]+{}[[]])[-~[]]+(+[]+[![]]+([]+{})[([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+{})[-~[]]+([]+{}[[]])[-~[]]+([]+![])[!![]-~[]-~[]]+([]+!![])[+[]]+([]+!![])[-~[]]+([]+{}[[]])[+[]]+([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+!![])[+[]]+([]+{})[-~[]]+([]+!![])[-~[]]])[[!![]-~[]]+[+[]]]]([!![]-~[]-~[]]+[!![]-~[]-~[]])+([]+!![])[-~[]]+([![]]+{}[[]])[-~[]+[+[]]]+([]+!![])[+[]]+([]+!![])[!![]-~[]-~[]]+([]+{})[+(-~[]+[+[]])+~[]+~[]+~[]]+([]+!![])[+[]]+(+(-~[]+[+[]]+[-~[]]))[([]+!![])[+[]]+([]+{})[-~[]]+(+[]+([]+{})[([]+{})[!![]-~[]-~[]-~[]-~[]]+([]+{})[-~[]]+([]+{}[[]])[-~[]]+([]
@rummik
rummik / gist:5960281
Created July 9, 2013 19:07
Nginx configs have gotten really short.
server {
server_name example.com;
return 301 http://www.example.com$uri;
}
server {
server_name www.example.com;
root /var/www/example.com;
try_files $uri /index.php?$args;