Skip to content

Instantly share code, notes, and snippets.

View nichtich's full-sized avatar
🦊
not a fox

Jakob Voß nichtich

🦊
not a fox
View GitHub Profile
@nichtich
nichtich / README.md
Last active February 13, 2024 23:39 — forked from oodavid/README.md
How to automatically deploy from GitHub
View README.md

Deploy your site with git

This gist assumes:

  • you have an online remote repository (github / bitbucket etc.)
  • you have a local git repo
  • and a cloud server (Rackspace cloud / Amazon EC2 etc)
    • your (PHP) scripts are served from /var/www/html/
    • your webpages are executed by Apache
  • the Apache user is named www-data (may be apache on other systems)
View data-package-context.md

A data-package is a dcat:dataset.

Aligned with DCAT-AP.

{
  "@type": "dcat:dataset",
  "name": {
  },
 "id": {
@nichtich
nichtich / wdquery
Last active November 22, 2023 09:27
Query Wikidata via SPARQL from command line
View wdquery
#!/bin/bash
#
# Run a Wikidata query from command line
#
# Usage examples:
#
# wdquery "DESCRIBE wd:Q42"
# wdquery - xml < query.sparql
# wdquery query.sparql json
#
@nichtich
nichtich / wiktionarylookup.html
Created November 12, 2010 19:10
Look up a word in Wiktionary via MediaWiki API and show the Wiktionary page
View wiktionarylookup.html
<html>
<head>
<script type="text/javascript" src="./jquery-1.4.3.min.js"></script>
<script type="text/javascript">
var baseURL = 'http://en.wiktionary.org';
function showPage(page,text) {
var sourceurl = baseURL + '/wiki/' + page;
$('#pagetitle').text(page);
$('#wikiInfo').html(text);
$('#sourceurl').attr('href',sourceurl);
@nichtich
nichtich / bibtex.bib
Last active July 30, 2023 19:30
Get CSL-Data for a given DOI
View bibtex.bib
@article{Williams_2010,
doi = {10.1371/journal.pone.0010676},
url = {http://dx.doi.org/10.1371/journal.pone.0010676},
year = 2010,
month = {may},
publisher = {Public Library of Science ({PLoS})},
volume = {5},
number = {5},
pages = {e10676},
author = {Jeffrey T. Williams and Kent E. Carpenter and James L. Van Tassell and Paul Hoetjes and Wes Toller and Peter Etnoyer and Michael Smith},
@nichtich
nichtich / README.md
Last active January 19, 2023 19:19
Ubuntu at Lenovo ThinkPad P14s
View README.md

Install and setup Ubuntu at a new Lenovo ThinkPad P14s Gen 3 with NVIDIA T550.

Lenovo is certified for Ubuntu

Lenovo provides a short document how to install Ubuntu 20.04

  • Enter BIOS and disable secure boot, to boot from USB Stick
  • Install Ubuntu, with "Install third-party software" enabled to include NVIDIA drivers

Update firmware

@nichtich
nichtich / viaflookup.pl
Created February 17, 2011 16:32
Make use of VIAF authority records
View viaflookup.pl
#!/usr/bin/perl
=head1 NAME
viaflookup.pl - How to make use of VIAF authority records
=head1 VERSION
Version 0.2 - 2011-02-18
@nichtich
nichtich / beacon2nt.awk
Created December 6, 2011 16:38
Simple awk scripts to convert between BEACON format and N-Triples
View beacon2nt.awk
# Simple awk script to convert BEACON format to N-Triples
# First published at https://gist.github.com/gists/1438869
# hereby put into public domain
BEGIN {
FS = "|"
link = "http://www.w3.org/2000/01/rdf-schema#seeAlso"
header = 1
}
{
if (header && $1 ~ /^(\xef\xbb\xbf)?[ \t]*#/) { # may contain UTF-8 BOM!
@nichtich
nichtich / jupyter-hosting.md
Last active September 7, 2022 19:10
Jupyter notebook hosting
View jupyter-hosting.md