This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import csv | |
import os | |
import exifread | |
# Prompt for directory to read from. | |
dir_name = input("Enter the directory to search [./]: ") | |
csv_file = input("Enter name for output file [output.csv]: ") | |
if dir_name == '': |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ACTION=="add", SUBSYSTEM=="tty", ATTRS{idVendor}=="067b", ATTRS{idProduct}=="2303", | |
SYMLINK+="serialgps", DRIVERS=="pl2303" TAG+="systemd", MODE="0666", ENV{SYSTEMD_WANTS}="serialgps.service" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import concurrent.futures | |
import time | |
import psycopg2 | |
import getpass | |
password = getpass.getpass(prompt='Password') | |
start = time.perf_counter() | |
def do_something(letter): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:xenial | |
RUN apt-get update | |
RUN apt-get install -y software-properties-common vim | |
RUN apt-get update | |
RUN apt-get install -y build-essential | |
RUN apt-get install -y git | |
RUN apt-get update -y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <FS.h> //this needs to be first, or it all crashes and burns... | |
#include <Wire.h> | |
#include <ESP8266WiFi.h> //https://github.com/esp8266/Arduino | |
#include <DNSServer.h> | |
#include <ESP8266WebServer.h> | |
#include <WiFiManager.h> //https://github.com/tzapu/WiFiManager | |
#include <ArduinoJson.h> //https://github.com/bblanchon/ArduinoJson | |
// MQTT Library | |
#include <PubSubClient.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
## Download your adafruit.io json data and load it. | |
## UTC_HOURS_OFFSET - Set to match your local offset. | |
import pandas as pd | |
import matplotlib.pyplot as plt | |
df = pd.read_json(ADAFRUITIO_JSON_DATAFILE) | |
# Change index to be usable by TimeGrouper(). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"github.com/spf13/viper" | |
) | |
// Create private data struct to hold config options. | |
type config struct { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# ex> '/home/on/the/range' will return 'range' | |
WORKDIR=${PWD##*/} | |
echo $WORKDIR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create a factory container that can run a specific version of NodeJS/npm/grunt/bower/gulp | |
FROM centos:7 | |
# Install any required system programs. In this case, 'wget' is is required for fetching the binaries. | |
RUN yum install -y wget | |
# Download specific version of NodeJS and install it on the system.. | |
RUN cd /opt; mkdir node-4.4.4; wget http://nodejs.org/dist/v4.4.4/node-v4.4.4-linux-x64.tar.gz; \ | |
tar zxvf node-v4.4.4-linux-x64.tar.gz --strip-components=1 -C ./node-4.4.4; rm -f node-v4.4.4-linux-x64.tar.gz; \ | |
ln -s /opt/node-4.4.4/bin/node /usr/local/bin/node; \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Jenkins | |
# This will allow you to run Jenkins as <HOST>/jenkins. | |
# Varnish 4 declaration | |
vcl 4.0; | |
# Backend is using the default Jenkins port. | |
backend jenkins { | |
.host = "127.0.0.1"; | |
.port = "8080"; |
NewerOlder