Skip to content

Instantly share code, notes, and snippets.


Márk Sági-Kazár sagikazarmark

View GitHub Profile
# -*- coding: UTF-8 -*-
from gi.repository import Gio
import sys
import appindicator
import gtk
class Screensaver:
def __init__(self):
sagikazarmark / Emitter
Last active Aug 29, 2015
Event Interop Interfaces
View Emitter
# Emitter/Dispatcher
This object is responsible for emitting/dispatching events to the listeners.
An Emitter can:
* Add listeners to the stack
* Return listeners (all, or the ones for a specific event)
* Remove listeners
* Emit an event
View task.php
class Task implements TaskInterface
public function run()
// ... some basic logic
// emit is just an example, the command logic is important here
$result = $this->emit(new InputCommand('Please give me some input!'));
sagikazarmark / ObjectStorageTest.php
Created Jan 2, 2015
Tests that the object storage dereferences objects stored
View ObjectStorageTest.php
class foo
public function __destruct()
echo 'Destructor called';
View SomeServiceProvider.php
class SomeServiceProvider
public $provides = array(
sagikazarmark / DbadException.php
Created Jan 30, 2015
In cases when your code is clearly not used for what it should be
View DbadException.php
* DBAD exception
* @link
class DbadException extends \Exception
sagikazarmark / phpserver.php
Created Apr 14, 2015
PHP server router script
View phpserver.php
* PHP Server router script
// determine the file we're loading, we need to strip the query string for that
if (isset($_SERVER['SCRIPT_NAME']))
sagikazarmark / package.gulp.json
Last active Aug 29, 2015
How not to use bower/grunt/gulp at all?
View package.gulp.json
"private": true,
"devDependencies": {
"bootstrap": "3.3.5",
"bootswatch": "3.3.5",
"browser-sync": "^2.8.0",
"browserify": "^11.0.0",
"del": "^1.1.1",
"domready": "^1.0.8",
"font-awesome": "4.3",
sagikazarmark /
Created Oct 13, 2015
List of currently available sitemap generators (and why they should be avoided)
View gist:9e8d2473e64a6fde9fa8
Verifying that +sagikazarmark is my blockchain ID.
You can’t perform that action at this time.