Skip to content

Instantly share code, notes, and snippets.

@asanchez75
asanchez75 / ImageMagick 6.9.7-4 Homebrew Formula.md
Last active February 3, 2018 19:34 — forked from afaur/ImageMagick 6.9.7-3 Homebrew Formula.md
Homebrew Formula for ImageMagick 6.9.7-4

Homebrew Formula patching old ImageMagick release 6.9.7-4

Install

$ brew install https://gist.githubusercontent.com/asanchez75/7c3cd4358fb982c4028bfc021424dfbc/raw/62eb3ce49d82b8a5c6033ecb89bdefbec9d00e84/imagemagick.rb

Tested

<VirtualHost *:80>
ProxyPreserveHost On
ServerName proxy-test.example.com
FilterDeclare MYFILTER
FilterProvider MYFILTER SUBSTITUTE resp=Content-Type $text/
FilterProvider MYFILTER SUBSTITUTE resp=Content-Type $/xml
FilterProvider MYFILTER SUBSTITUTE resp=Content-Type $/json
FilterProvider MYFILTER SUBSTITUTE resp=Content-Type $/javascript
<Location />
#disable gzip
@asanchez75
asanchez75 / freetds_install_ubuntu_14.md
Created July 22, 2017 10:48 — forked from ghalusa/freetds_install_ubuntu_14.md
Installing and Configuring FreeTDS on Ubuntu 14.04.4 LTS and Establish a Connection via PHP PDO

Installing and Configuring FreeTDS on Ubuntu 14.04.4 LTS and Establish a Connection via PHP PDO


Install

sudo apt-get install -y unixodbc unixodbc-dev unixodbc-bin libodbc1 odbcinst1debian2 tdsodbc php5-odbc
@asanchez75
asanchez75 / RDFLib+python+Virtuoso
Created October 14, 2017 19:20 — forked from rancas/RDFLib+python+Virtuoso
A practical example to show how you can connect to a Virtuoso quad-store with python and rdflib.
from rdflib.graph import ConjunctiveGraph as Graph
from rdflib.store import Store
from rdflib.plugin import get as plugin
from rdflib.term import URIRef
Virtuoso = plugin("Virtuoso", Store)
store = Virtuoso("DSN=VOS;UID=dba;PWD=dba;WideAsUTF16=Y")
default_graph_uri = "http://www.w3.org/People/Berners-Lee/card"
graph = Graph(store,identifier = URIRef(default_graph_uri))
@asanchez75
asanchez75 / docker-compose.yml
Created October 17, 2017 04:11 — forked from mystygage/docker-compose.yml
Microsoft SQL Server in Docker with data volume
version: '3'
services:
mssql-server-linux:
image: microsoft/mssql-server-linux:latest
volumes:
- mssql-server-linux-data:/var/opt/mssql/data
environment:
- ACCEPT_EULA=Y
- SA_PASSWORD=${SQLSERVER_SA_PASSWORD:-yourStrong(!)Password}
@asanchez75
asanchez75 / mbe_book_paragraph.csv
Created November 5, 2017 19:52 — forked from dinarcon/mbe_book_paragraph.csv
Drupal 8 migrations by example
Professor ID Title Author
P01 The pushcart war Jean Merrill
P02 The definite guide to Drupal 7 Benjamin Melançon et al.
P03 The five love languages Gary Chapman
@asanchez75
asanchez75 / QueryDOM.php
Created November 28, 2017 08:42 — forked from hubgit/QueryDOM.php
Add XPath methods to DOMDocument
<?php
class QueryDOMDocument extends \DOMDocument
{
/** @var \DOMXPath */
protected $xpath;
public function __construct()
{
parent::__construct();
@asanchez75
asanchez75 / curl.md
Created December 9, 2017 11:59 — forked from subfuzion/curl.md
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@asanchez75
asanchez75 / demo1.results
Last active January 12, 2018 09:33 — forked from mepcotterell/demo1.results
Example SPARQL Queries
yago:Albert_Einstein yago:hasAcademicAdvisor yago:Alfred_Kleiner .
@asanchez75
asanchez75 / SPARQLWrapper-HTTP-Digest-Auth-example.py
Last active January 29, 2018 10:08 — forked from wikier/SPARQLWrapper-HTTP-Digest-Auth-example.py
SPARQLWrapper HTTP Digest Auth example
from SPARQLWrapper import SPARQLWrapper, JSON, DIGEST
sparql = SPARQLWrapper("http://example.org/sparql")
# For Virtuoso, use BASIC, not DIGEST
sparql.setHTTPAuth('BASIC')
sparql.setCredentials('login', 'password')
sparql.setQuery("...")
sparql.setReturnFormat(JSON)