Skip to content

Instantly share code, notes, and snippets.

View csarven's full-sized avatar
👽
https://csarven.ca/#i

Sarven Capadisli csarven

👽
https://csarven.ca/#i
View GitHub Profile
$('#views.lr button').on('click', function(event) {
var selected = $(this);
$('head link[rel~="stylesheet"]:not([href$="lr.css"])').each(function(i, stylesheet) {
if ($(this).prop('title').toLowerCase() == selected.text().toLowerCase()) {
var s = $('<link>').prop({type: 'text/css', rel: 'stylesheet', href: $(this).prop('href'), title: $(this).prop('title')});
}
else {
var s = $('<link>').prop({type: 'text/css', rel: 'stylesheet alternate', href: $(this).prop('href'), title: $(this).prop('title')});
}
@csarven
csarven / gist:b1af825f489796f28b6d
Last active August 29, 2015 14:20
gulp browser output
$ uname -a
Linux nevrasc 3.13.0-51-generic #84-Ubuntu SMP Wed Apr 15 12:08:34 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
$ gulp -v
[18:02:30] CLI version 3.8.11
[18:02:30] Local version 3.8.11
$ gulp browser
[18:01:48] Using gulpfile /var/www/rdfstore-js/gulpfile.js
[18:01:48] Starting 'parseGrammar'...
Issued to: E=info@csarven.ca,CN=Sarven Capadisli,OU=http://csarven.ca/,O=http://csarven.ca/
Serial Number: 00:95:53:F3:96:F3:5A:05:B7
Valid from 2012-12-08 15:11:55 to 2112-11-14 15:11:55
Email: info@csarven.ca
Issued by: E=info@csarven.ca,CN=Sarven Capadisli,OU=http://csarven.ca/,O=http://csarven.ca/
Stored in: Software Security Device
Request==========
Accept
text/turtle,text/n3,application/rdf+xml
#!/bin/bash
git clone https://github.com/nicola/simplerdf.git
cd simplerdf
sudo npm install rdf-store-ldp -g
sudo npm install rdf-ext -g
sudo npm install browserify -g
browserify index.js > simplerdf.js
/* ceur-ws.css defines how links are displayed and */
/* possibly some other details of page rendering within */
/* CEUR-WS.org. */
/* Copyright 2002-2015 by Manfred Jeusfeld */
/* Use permitted within CEUR-WS.org. */
/* Modification permitted for members of the CEUR-WS TEAM.*/
/* */
/* THIS STYLE FILE IS FOR EXCLUSIVE USE WITHIN */
/* CEUR-WS.ORG! DO NOT COPY IT AS A WHOLE OR AS PARTS. */
/* IN PARTICULAR, THE TAGS CEUR* DEFINED BELOW MAY NOT BE */
/* ceur-ws.css defines how links are displayed and */
/* possibly some other details of page rendering within */
/* CEUR-WS.org. */
/* Copyright 2002-2015 by Manfred Jeusfeld */
/* Use permitted within CEUR-WS.org. */
/* Modification permitted for members of the CEUR-WS TEAM.*/
/* */
/* THIS STYLE FILE IS FOR EXCLUSIVE USE WITHIN */
/* CEUR-WS.ORG! DO NOT COPY IT AS A WHOLE OR AS PARTS. */
/* IN PARTICULAR, THE TAGS CEUR* DEFINED BELOW MAY NOT BE */
@csarven
csarven / gist:4650969
Last active December 11, 2015 19:48
tdb.sdmx.ttl
Imported data to named graphs into TDB using the following assembler files:
tdb.5B0.ttl
@prefix tdb: <http://jena.hpl.hp.com/2008/tdb#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix ja: <http://jena.hpl.hp.com/2005/11/Assembler#> .
[] ja:loadClass "com.hp.hpl.jena.tdb.TDB" .
/usr/lib/jena/trunk/apache-jena$ sudo mvn install
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Building Apache Jena - Distribution
[INFO] task-segment: [install]
[INFO] ------------------------------------------------------------------------
[INFO] [remote-resources:process {execution: default}]
[INFO] [site:attach-descriptor {execution: default-attach-descriptor}]
[INFO] [assembly:single {execution: create-jena-download}]
[INFO] Reading assembly descriptor: assembly-jena-zip.xml
@csarven
csarven / gist:5198926
Created March 19, 2013 18:43
org.apache.jena.riot.RiotException: No graph writer for null
[2013-03-19 19:39:05] INFO Fuseki :: [1] GET http://localhost:3030/dataset/query?query=%0ADESCRIBE+%3Chttp%3A%2F%2Fexample.info%2Fid%2F1000%3E%0A&output=html
[2013-03-19 19:39:05] INFO Fuseki :: [1] Host localhost:3030
[2013-03-19 19:39:05] INFO Fuseki :: [1] Accept */*
[2013-03-19 19:39:05] INFO Fuseki :: [1] Query =
DESCRIBE <http://example.info/id/1000>
[2013-03-19 19:39:05] DEBUG TDB :: Txn[1]/R: begin$
[2013-03-19 19:39:05] DEBUG info :: Triple table: SPO :: SPO,POS,OSP
[2013-03-19 19:39:05] DEBUG info :: Quad table: GSPO :: GSPO,GPOS,GOSP,POSG,OSPG,SPOG
@csarven
csarven / gist:5221536
Last active December 15, 2015 07:09
Exports of goods and services (BoP, current US$) for CH
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX wgs: <http://www.w3.org/2003/01/geo/wgs84_pos#>
PREFIX dbo: <http://dbpedia.org/ontology/>
PREFIX dbp: <http://dbpedia.org/property/>