Skip to content

Instantly share code, notes, and snippets.

View shvelo's full-sized avatar

Nikoloz Shvelidze shvelo

View GitHub Profile
@shvelo
shvelo / gist:7563808
Last active December 28, 2015 21:19
Get distribution name from shell
grep -Po "DISTRIB_ID=(\K.*)" /etc/lsb-release
@shvelo
shvelo / Clock.pde
Created June 20, 2013 16:29
Arduino Mega2560 | Library: https://github.com/rodan/ds3231 | Pins: SDA to Pin20 | SCL to Pin21 | VCC to 5v | GND to GND |
// include the library code:
#include <LiquidCrystal.h>
#include <Wire.h>
#include "ds3231.h"
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
int sensorValue;
@shvelo
shvelo / load_jquery.js
Last active December 16, 2015 01:19
Load jQuery on any page
var s = document.createElement('script');
s.src = "http://code.jquery.com/jquery-latest.min.js";
document.body.appendChild(s);
@shvelo
shvelo / gist:4749455
Last active December 12, 2015 09:09
Quick notepad, paste in your address bar and go
data:text/html, <html contenteditable><title>Notepad</title><body style="padding:1em;font-family:sans-serif;color: #2d2d2d;font-size:1.5em">
@shvelo
shvelo / 2years.log
Created June 17, 2012 20:19
output of generator
Year: 2012
Name: Sim Hill
Population: 269
Mayor: Steve Lombardi Sr.
Map:
█░░██░░█░██░░░█░█░█░░░░█░██████░░█░░█░
█░░█░█░░░███░░██░█████░░█░░█░░█████░█░
█████░█░██░░███░░░░░███░░█░█░██░░█░░░░
██░░░█░█░█░░░░██░█░░░█░░░██░██░██░██░█
░░░█░███████████░░██░█░█████░█░█░░░░██