This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Scripts: | |
-------- | |
ps aux | grep -i firefox | awk '{sum += $4} END {print 4*1024 * (sum/100)}' | |
ps aux | grep -i safari | awk '{sum += $4} END {print 4*1024 * (sum/100)}' | |
ps aux | grep -i chrome | awk '{sum += $4} END {print 4*1024 * (sum/100)}' | |
Time-Table: | |
----------- | |
Name Mega |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class MyArray extends ArrayObject { | |
function __construct($array = array()){ | |
parent::__construct($array, ArrayObject::ARRAY_AS_PROPS); | |
} | |
public function get_property_string($sep = ':') { | |
return implode($sep, $this->getArrayCopy()); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Show current song | |
-- by Balazs Nadasdi | |
set the enabledNotification to {"iTunes Current Song"} | |
tell application "System Events" | |
set isGrowlRunning to (count of (every process whose bundle identifier is "com.Growl.GrowlHelperApp")) > 0 | |
set isiTunesRunning to (count of (every process whose bundle identifier is "com.apple.iTunes")) > 0 | |
end tell |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'xmlsimple' | |
old_file = ARGV[0] rescue nil | |
new_file = ARGV[1] rescue nil | |
output = ARGV[2] rescue nil | |
if old_file.nil? or new_file.nil? | |
puts "#{$0} <old_string.xml> <new_string.xml> [output_string.xml]" | |
exit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="hu"> | |
<head> | |
<title>DIV refresh page</title> | |
<meta charset="utf-8" /> | |
<script type="text/javascript" src="http://code.jquery.com/jquery-1.8.0.min.js"></script> | |
<script type="text/javascript"> | |
// en jobban szeretem a jQuery format mint a jQuery-et | |
// mert igy kisebb az esely hogy osszeakad massal :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Set a trigger: | |
* onFormSubmit -> getDisplayName | |
* | |
* Form: Google+ ID (must be the first column in the form) | |
* or you need to change `id = e.values[1];` line | |
* in getDisplayName function to the correct column number | |
* | |
* Author: Balazs Nadasdi | |
* <[email protected]> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE HTML> | |
<html lang="en-US"> | |
<head> | |
<meta charset="UTF-8"> | |
<title></title> | |
<link href="data:image/x-icon;base64,AAABAAEAEBACAAAAAACwAAAAFgAAACgAAAAQAAAAIAAAAAEAAQAAAAAAQAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAA////AAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD//gAA//8AAP//AAD//wAA//8AAP//AAD//wAA//8AAP//AAD//wAA//8AAP//AAD//wAA//8AAP//AAD//wAA" rel="icon" type="image/x-icon" /></head> | |
<body> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(function() { | |
jQuery('iframe').each(function(index, element) { | |
var elm = jQuery(element); | |
if (elm.attr('src').match(/youtube/)) { | |
var code = elm.attr('src').replace(/http:\/\/[^\/]+\/[^\/]+\/([^\/]+)\?.*/, "$1"); | |
var link = jQuery('<a>'); | |
link.html('download').attr('href', "http://www.audiothief.com/xx-xx/Video/PluginConvert/" + code); | |
elm.after(link); | |
} | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var cloned = false; | |
var cloneTick = 0; | |
//FightCode can only understand your robot | |
//if its class is called Robot | |
var Robot = function(robot) { | |
}; | |
Robot.prototype.onIdle = function(ev) { | |
var robot = ev.robot; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//FightCode can only understand your robot | |
//if its class is called Robot | |
var Robot = function(robot) {}; | |
var target = null; | |
var intelAge = 0; | |
var cloned = false; | |
var pointAt = function(robot, enemy) |