Skip to content

Instantly share code, notes, and snippets.

@Fabryz
Fabryz / gist:1298220
Created October 19, 2011 13:04
Error while installing on Mac OSX 10.7 Lion
H-arts-iMac:nodetest fcodello$ sudo curl http://npmjs.org/install.sh | sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 7031 100 7031 0 0 9198 0 --:--:-- --:--:-- --:--:-- 27790
tar=/usr/bin/tar
version:
bsdtar 2.8.3 - libarchive 2.8.3
Installing without make. This may fail.
fetching: http://registry.npmjs.org/npm/-/npm-1.0.99.tgz
0.4.12
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"><html>
<head>
<meta name="Status: Mark 7" content="2012">
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1" >
<title>Status: Mark 7</title>
</head>
<body bgcolor="#000000">
@Fabryz
Fabryz / compact
Created February 27, 2012 15:26
Calderan's Resolutions
javascript:(function(){var a=document.createElement("script");a.src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js";a.onload=a.onreadystatechange=function(){$("<div/>",{html:"Resize window",id:"debug"}).appendTo("body");var a=$("#debug");a.css({"z-index":"9999",position:"absolute",top:"5px",right:"5px",padding:"5px",border:"2px #d8d8dc solid",color:"#2068a5",font:"16px Arial, sans-serif","font-weight":"bold",background:"rgba(220,220,220,.85)"});$(window).resize(function(){var b=Math.floor($(window).width()),c=Math.floor($(window).height());a.html(b+"x"+c)})};document.body.appendChild(a)})();
➜ mirror git:(master) ✗ sudo npm cache clean && sudo rm -rf /usr/local/lib/node_modules/jitsu
npm ERR! Error: ENOTEMPTY, rmdir '/Users/fcodello/.npm/npm/1.1.0/package/node_modules/fstream/examples/path/to'
npm ERR! You may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-@googlegroups.com>
npm ERR!
npm ERR! System Darwin 11.2.0
npm ERR! command "node" "/usr/local/bin/npm" "cache" "clean"
@Fabryz
Fabryz / Exception
Created May 18, 2012 23:17
Wurm client error
JNLPSigningException[Convalida della firma del file di avvio non riuscita. La versione firmata non corrisponde alla versione scaricata.]
at com.sun.javaws.jnl.LaunchDesc.checkSigning(Unknown Source)
at com.sun.javaws.LaunchDownload.checkSignedLaunchDescHelper(Unknown Source)
at com.sun.javaws.LaunchDownload.checkSignedLaunchDesc(Unknown Source)
at com.sun.javaws.Launcher.prepareResources(Unknown Source)
at com.sun.javaws.Launcher.prepareAllResources(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.launch(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
➜ tweet-a-table git:(master) ✗ sudo npm install
npm http GET https://registry.npmjs.org/jquery
npm http GET https://registry.npmjs.org/jade
npm http GET https://registry.npmjs.org/socket.io
npm http GET https://registry.npmjs.org/express
npm http 304 https://registry.npmjs.org/jquery
npm http 304 https://registry.npmjs.org/jade
npm http 304 https://registry.npmjs.org/express
npm http 304 https://registry.npmjs.org/socket.io
npm http GET https://registry.npmjs.org/mime/1.2.4
@Fabryz
Fabryz / gist:3077360
Created July 9, 2012 16:07
jquery.js
/*!
* jQuery JavaScript Library v1.7.2
* http://jquery.com/
*
* Copyright 2011, John Resig
* Dual licensed under the MIT or GPL Version 2 licenses.
* http://jquery.org/license
*
* Includes Sizzle.js
* http://sizzlejs.com/
@Fabryz
Fabryz / gist:3157500
Created July 21, 2012 23:05
HTTP Headers
javascript:(function(){function read(url){var r=new XMLHttpRequest();r.open('HEAD',url,false);r.send(null);return r.getAllResponseHeaders();}alert(read(window.location))})();
@Fabryz
Fabryz / gist:3293643
Created August 8, 2012 09:06
How to install Node.js on Linux
$ sudo apt-get install git-core python libssl-dev build-essential
$ git clone git://github.com/joyent/node.git node && cd node
$ git checkout v0.8.6 (or check the latest stable version on https://github.com/joyent/node/tags)
$ ./configure
$ make (it will take some time)
$ sudo make install
Do a check with:
$ node -v
➜ phantomjs git:(master) qmake-qt4 && make
cd src/ && make -f Makefile.phantomjs
make[1]: Entering directory `/home/fabryz/Documenti/www-node/phantomjs/src'
g++ -c -m64 -pipe -O2 -Wall -W -D_REENTRANT -DQT_WEBKIT -DHAVE_CONFIG_H -DHAVE_FCNTL_H -DHAVE_STDARG_H -DHAVE_STDINT_H -DHAVE_UNISTD_H -DUSE_UTF8 -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++-64 -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -Igif -Imongoose -Ilinenoise/src -Ibreakpad/src -I. -o phantom.o phantom.cpp
In file included from phantom.cpp:44:0:
webpage.h:49:1: error: expected class-name before ‘{’ token
phantom.cpp: In member function ‘void Phantom::loadModule(const QString&, const QString&)’:
phantom.cpp:314:66: error: no matching function for call to ‘QWebFrame::evaluateJavaScript(QString&, const QString&)’
phantom.cpp:314:66: note: candidate is:
/usr/include/qt4/QtWebKit/qwebframe.h