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
| (function($){ | |
| /** | |
| * 1.0 | |
| * Author Ivan Scherbak dev@funivan.com | |
| * $('#title').ukrtranslit('#sef'); | |
| * | |
| */ | |
| $.fn.extend({ | |
| ukrtranslit : function(el) { | |
| var translitTable = new Array(); |
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
| // Just add this text to bookmark panel | |
| javascript:(function () {ISRIL_SCRIPT = document.createElement('SCRIPT');ISRIL_SCRIPT.type = 'text/javascript';ISRIL_SCRIPT.src='http://localhost/Fiv/tools/saveForFun/save.js';document.getElementsByTagName('head')[0].appendChild(ISRIL_SCRIPT)})(); | |
| // Next content save to http://localhost/Fiv/tools/saveForFun/save.js | |
| // | |
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 | |
| error_reporting(E_ALL); | |
| ini_set('display_errors', 1); | |
| class ExportHtml { | |
| const SAVE_DIR = '/home/ivan/Ubuntu One/saved'; |
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_error_handler('exceptions_error_handler'); | |
| function exceptions_error_handler($severity, $message, $filename, $lineno) { | |
| if (error_reporting() == 0) { | |
| return; | |
| } | |
| if (error_reporting() & $severity) { | |
| throw new ErrorException($message, 0, $severity, $filename, $lineno); |
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
| <? | |
| /** | |
| * https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Process/PhpExecutableFinder.php#L49 | |
| */ | |
| if ($php = getenv('PHP_PEAR_PHP_BIN')) { | |
| if (is_executable($php)) { | |
| return $php; | |
| } | |
| } |
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
| # -*- coding: UTF-8 -*- | |
| from __future__ import with_statement | |
| __kupfer_name__ = _("Custom urls") | |
| __kupfer_sources__ = ("CustomUrlSource", ) | |
| __description__ = _("Navigate to custom urls from list") | |
| __version__ = "0.0.1" | |
| __author__ = "Ivan Scherbak <dev@funivan.com>" | |
| import gtk |
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
| // gcc -o v8 v8.c && chmod +x v8 && sudo ./v8 | |
| // cat /proc/bus/input/devices | |
| #include <stdlib.h> | |
| #include <unistd.h> | |
| #include <fcntl.h> | |
| #include <errno.h> | |
| #include <string.h> | |
| #include <stdio.h> | |
| #include <linux/input.h> |
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
| -Xms128m | |
| -Xmx750m | |
| -XX:MaxPermSize=350m | |
| -XX:ReservedCodeCacheSize=225m | |
| -ea | |
| -Dsun.io.useCanonCaches=false | |
| -Djava.net.preferIPv4Stack=true | |
| -Djsse.enableSNIExtension=false | |
| -XX:+UseConcMarkSweepGC | |
| -XX:SoftRefLRUPolicyMSPerMB=50 |
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
| #!/usr/bin/env python | |
| # | |
| # Remember you need dbus session to run this program. | |
| # export DBUS_SESSION_BUS_ADDRESS=`cat /proc/$(pidof gnome-session)/environ | tr '\\0' '\\n' | grep DBUS_SESSION_BUS_ADDRESS | cut -d '=' -f2-`; | |
| # | |
| import socket | |
| import dbus, gobject | |
| from dbus.mainloop.glib import DBusGMainLoop | |
| import os | |
| import sys |
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
| #!/bin/bash | |
| fps=7 | |
| avconv -start_number 0035 -f image2 -r $fps -i %04d.JPG -q:v 1 -b:v 1000K time-lapse.avi | |
| a=1 | |
| for i in *.JPG; do | |
| new=$(printf "%04d.JPG" ${a}) #04 pad to length of 4 |