Skip to content

Instantly share code, notes, and snippets.

View gousiosg's full-sized avatar

Georgios Gousios gousiosg

View GitHub Profile
@gousiosg
gousiosg / nagios.nginx
Last active February 16, 2018 10:56
Nagios on a virtual host with nginx on Debian
server {
listen 80;
server_name nagios.tld.org;
access_log /var/log/nginx/nagios.access.log;
error_log /var/log/nginx/nagios.error.log info;
root /usr/share/nagios3/htdocs;
index index.php index.html;
@gousiosg
gousiosg / pink_rubies.dot
Last active April 3, 2018 11:49
33 pink rubies
digraph g {
rankdir=LR;
graph [fontname = "helvetica"];
node [shape=record, fontname = "helvetica"];
edge [fontname = "helvetica"];
1 -> 95;
1 -> 10;
2 -> 78;
#!/usr/bin/env python
# (c) 2018 Georgios Gousios <gousiosg@gmail.com>
#
# Barebones linear equation solving trainer
from __future__ import division
from random import randint
import codecs
import sys
highlight -O rtf -s seashell -k Monaco -K 20 foo.rb |pbcopy
@inproceedings{wang2019could,
title={Could I Have a Stack Trace to Examine the Dependency Conflict Issue?},
author={Wang, Ying and Wen, Ming and Wu, Rongxin and Liu, Zhenwei and Tan, Shin Hwei and Zhu, Zhiliang and Yu, Hai and Cheung, Shing-Chi},
year={2019},
booktitle={ICSE 2019},
Note = {
The authors consider the problem of dependency conflicts.
This happens when imported libraries include classes of the same name or multiple versions of the same library are imported.
The authors found several issues on GitHub related to dependency conflicts.
The build a full scale CFG (including the program and dependencies) and they initially short-circuit all branch conditions
@gousiosg
gousiosg / rebuild_megaraid.md
Last active February 4, 2020 10:09
Rebuild RAID array when one disk has been marked as faulty (but it is not really)
@gousiosg
gousiosg / developer-density.ipynb
Last active November 6, 2020 17:43
Developer density
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@gousiosg
gousiosg / geocode.rb
Created October 8, 2015 21:27
Geocode a list of addresses using OpenStreetMaps
#!/usr/bin/env ruby
#
require 'open-uri'
require 'json'
require 'pp'
require 'uri'
File.open('locs').each_line do |location|
url=URI.escape("http://nominatim.openstreetmap.org/search/#{location}?format=json&addressdetails=1")
@gousiosg
gousiosg / buien-hue.rb
Last active December 9, 2020 10:22
Set color of a Hue lightbulb based on fine-grained rain information
#!/usr/bin/env ruby
require 'open-uri'
require 'json'
require 'hue'
delft="http://www.buienradar.nl/Json/RainForecast3Hours?lat=52.006&lon=4.355&weatherstationid=6344&streetlevel=false"
percipitation = JSON.parse(open(delft).read)['forecasts'][1]["precipation"]
@gousiosg
gousiosg / ml4se.bib
Last active December 9, 2020 13:29
My reading list for ML4SE
@article{Alon19,
author = {Alon, Uri and Zilberstein, Meital and Levy, Omer and Yahav, Eran},
title = {Code2Vec: Learning Distributed Representations of Code},
journal = {Proc. ACM Program. Lang.},
issue_date = {January 2019},
volume = {3},
number = {POPL},
month = jan,
year = {2019},
issn = {2475-1421},