Skip to content

Instantly share code, notes, and snippets.

View indeyets's full-sized avatar

Alexey Zakhlestin indeyets

View GitHub Profile
@indeyets
indeyets / appserver.php
Created March 7, 2014 19:49
Example of simple PHP application conversion to use https://github.com/indeyets/appserver-in-php
<?php
/**************************
* aip variant of php file
**************************/
class MyApp
{
public function __invoke($context)
{
$output = '<h1>Hello world</h1>';
@indeyets
indeyets / list.txt
Last active August 29, 2015 13:57
My installed Casks http://caskroom.io/
adium
android-file-transfer
anki
audacity
boxer
calibre
cog
cyberduck
dfontsplitter
dropbox
@indeyets
indeyets / virtuoso.py
Created May 9, 2014 12:32
Virtuoso helper for SPARQLWrapper 1.6.0
from SPARQLWrapper import SPARQLWrapper
class VirtuosoWrapper(SPARQLWrapper):
def setParameter(self, name, value):
self.clearParameter(name)
return self.addParameter(name, value)
def setReturnFormat(self, output_format):
if output_format == 'jsonld':
@indeyets
indeyets / merge.php
Created May 20, 2014 08:20
EasyRDF graph-merge example
<?php
require '../vendor/autoload.php';
$graph1 = new EasyRdf_Graph();
$graph1->addResource('http://example.org/1', 'dc:title', 'Hello, world!');
$graph1->addResource('http://example.org/2', 'dc:description', 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.');
$graph2 = new EasyRdf_Graph();
$graph2->addResource('http://example.org/1', 'dc:description', 'Some boring description');
$graph2->addResource('http://example.org/2', 'dc:title', 'Hello, second world!');

Keybase proof

I hereby claim:

  • I am indeyets on github.
  • I am jimidini (https://keybase.io/jimidini) on keybase.
  • I have a public key whose fingerprint is A6CE DC75 11EF 851C 3D7A 48DA AF54 312A 1D21 9F11

To claim this, I am signing this object:

@indeyets
indeyets / steps.txt
Created April 6, 2015 20:01
Mink's steps
default | Given /^(?:|I )am on (?:|the )homepage$/
| Opens homepage.
| at `FeatureContext::iAmOnHomepage()`
default | When /^(?:|I )go to (?:|the )homepage$/
| Opens homepage.
| at `FeatureContext::iAmOnHomepage()`
default | Given /^(?:|I )am on "(?P<page>[^"]+)"$/
| Opens specified page.
<?php
class Symfony2App
{
private $kernel;
public function __construct(\Symfony\Foundation\Kernel $kernel)
{
$this->kernel = $kernel;
}
diff --git a/configure b/configure
index 3245683..070ac7b 100755
--- a/configure
+++ b/configure
@@ -17807,171 +17807,11 @@ fi
$as_echo "Mac OS X - carbon" >&6; }
platform_carbon=yes
SOPREFIX='lib'
-
- # Check whether --enable-binreloc was given.
@indeyets
indeyets / gist:666118
Created November 7, 2010 13:15
gda-4.0.12 introspection patch
diff --git a/libgda/gda-data-model.c b/libgda/gda-data-model.c
index 1518918..fa711f1 100644
--- a/libgda/gda-data-model.c
+++ b/libgda/gda-data-model.c
@@ -898,7 +898,7 @@ gda_data_model_remove_row (GdaDataModel *model, gint row, GError **error)
/**
* gda_data_model_get_row_from_values:
* @model: a #GdaDataModel object.
- * @values: (element-type Gobject.Value): a list of #GValue values (no %NULL is allowed)
+ * @values: (element-type GObject.Value): a list of #GValue values (no %NULL is allowed)
@indeyets
indeyets / gist:672998
Created November 11, 2010 19:04
mongrel2 formula patch for homebrew
diff --git a/Library/Formula/mongrel2.rb b/Library/Formula/mongrel2.rb
index 60e7e49..35ce213 100644
--- a/Library/Formula/mongrel2.rb
+++ b/Library/Formula/mongrel2.rb
@@ -9,6 +9,8 @@ class Mongrel2 <Formula
depends_on 'zeromq'
def install
+ ENV['OPTFLAGS'] = ENV.cflags + " " + ENV['CPPFLAGS']
+ ENV['OPTLIBS'] = ENV.ldflags