Skip to content

Instantly share code, notes, and snippets.

@patmandenver
patmandenver / setenv.sh
Created August 16, 2015 15:30
Tomcat8 setenv.sh
#
# Cutom Environment Variables for Tomcat
#
############################################
export JAVA_HOME=/usr/lib/jvm/java-7-oracle/jre
export PATH=${JAVA_HOME}/bin:${PATH}
############################################
#
# JAVA_OPTS
$fn=100;
grand_teton="grand_tetons.stl";
adjust=[0,0,2]; // X,Y,Z adjustments
just_display=false; //Set to false to split
split=true;//Set to false to adjust
//Split size in mm
edge=20;
//split per side
#!/usr/bin/env python3
import openpyxl
import json
from openpyxl import Workbook
def populate_sheet(json_data, sheet):
sheet.cell(1,1, "Month")
sheet.cell(1,2, "food")
#!/usr/bin/env python3
import openpyxl
import json
from openpyxl import Workbook
#############################################
# MAIN
#############################################
@patmandenver
patmandenver / scp-speed-test.sh
Last active March 28, 2023 04:10
scp speed test between servers
#!/bin/bash
# scp-speed-test.sh
#
# Usage:
# ./scp-speed-test.sh user@hostname [test file size in MBs]
#
#############################################################
ssh_server=$1
test_file=".scp-test-file"
#!/usr/bin/env python3
import openpyxl
import json
from openpyxl import Workbook
from openpyxl.styles import numbers
from openpyxl.utils import get_column_letter
header_dict = { "1": "Month",
@patmandenver
patmandenver / save_multiple_icons.jsx
Last active September 20, 2022 09:38
Photoshop script to save a file in multiple different sizes as a png file
// Create Multiple icon files
// Author: Patrick Bailey
// License: MIT
//
//Copyright 2017 T. Patrick Bailey
//Permission is hereby granted, free of charge, to any person obtaining a copy
//of this software and associated documentation files (the "Software"), to
//deal in the Software without restriction, including without limitation the
//rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
//sell copies of the Software, and to permit persons to whom the Software is
@patmandenver
patmandenver / lambda slack relay
Created December 17, 2017 22:09
An AWS lambda slack webhook relay (make sure to change the path to your actual slack webhook URL
var https = require('https');
exports.handler = (event, context, callback) => {
console.log("MYLOG" + JSON.stringify(event))
//Custom Fields sent in from Distilio
var body = JSON.parse(event.body)
var name = body.name
var uri = body.uri
//
// Created by Patrick Bailey iQless.com
//
////////////////////////////////////////
$fn=200;
moai_statue = "moai-small-no_overhang.stl";
magnet_dia = 32.2; //33 too big
//
// Created by Patrick Bailey iQless.com
//
////////////////////////////////////////
$fn=200;
moai_statue = "moai-small-no_overhang.stl";
moau_plug = "giant_moai_plug.stl";