Skip to content

Instantly share code, notes, and snippets.

@jpeak5
jpeak5 / expand-multivalue-csv-columns.py
Last active October 10, 2024 03:33
This script expands rows in CSV files containing multivalue column.
#!/usr/bin/env python
"""This script expands rows in CSV files containing multivalue column.
Run with -h to learn more about its arguments.
"""
import argparse
import csv
import logging
import sys
@jpeak5
jpeak5 / create-users.sh
Last active October 5, 2018 19:55
Script to remind me how to quickly make sudo users on ubuntu
#! /bin/bash
## this script expects that public keys at $keyspath
## will have the form 'username.pub' where username
## will be used to create a new user account.
workdir=/tmp/create-users-wkdir
mkdir $workdir
cd $workdir
<map version="1.0.1">
<!-- To view this file, download free mind mapping software FreeMind from http://freemind.sourceforge.net -->
<node CREATED="1533750337556" ID="ID_900528234" MODIFIED="1533750339627" TEXT="aspace">
<node CREATED="1533750359490" FOLDED="true" ID="ID_607694328" MODIFIED="1533829355652" POSITION="right" TEXT="backup">
<linktarget COLOR="#b0b0b0" DESTINATION="ID_607694328" ENDARROW="Default" ENDINCLINATION="224;0;" ID="Arrow_ID_960021642" SOURCE="ID_1659470692" STARTARROW="None" STARTINCLINATION="224;0;"/>
<node CREATED="1533751063902" ID="ID_957267572" MODIFIED="1533752021974" TEXT="frequency">
<node CREATED="1533751016097" ID="ID_393949" MODIFIED="1533829319341" TEXT="1 daily"/>
<node CREATED="1533751020211" ID="ID_760409150" MODIFIED="1533751046816" TEXT="1 weekly"/>
<node CREATED="1533751022896" ID="ID_1076624300" MODIFIED="1533751042532" TEXT="1 monthly"/>
<node CREATED="1533751026037" ID="ID_207340357" MODIFIED="1533751033552" TEXT="6 mo ago"/>

Questions

  • How old are the following items?: - Is paperwork (warranty) available for these items ?
    • Roofing – April 2009, Cribbs Inc.
      • warranty: the shingle manufacturer provides a 30-year prorated warranty against manufacturing defects; contact Cribbs.inc to make a claim
    • Heating/Cooling system
      • In June 2017, AccuTemp replaced attic and outside units (will send warranty info this evening)
    • Hot water heater
      • new in 2006
  • Kitchen appliances

Small teams

Project-oriented teams define scope-appropriate rules of the road, including internal/external update frequency, pre-delivery review schedule,

Prototyping

Development workflow for new projects should use an Evolutionary prototyping model.

Tracking

An excellent system or small set of excellent interlinked systems (document sys. + task sys. as in Key1) should contain the searchable history of every project, bug report, system configuration, task breakdown, release plan, etc, AND it should expose public and private facets for curated Documentation.

Scoped meetings

The system

Needed to:

  • impose some order on the chaos of a group
  • enable efficient work
  • direct/inform communication activities
  • facilitate appropriate information sharing

Summary

@jpeak5
jpeak5 / delivery.md
Last active February 19, 2018 20:18
Draft milestones for product delivery

Product delivery

Goal

Handover of LDL from dev team to ops team, moving into a maintenance/feature-building stage.

  • We are no longer 'building the LDL' (project with unlimited scope)
  • work continues, but projects are scoped/contained
  • policies are well-defined, written, and available
  • service level is well-defined, available, and its terms are agreed by stakeholders
@jpeak5
jpeak5 / git-versions
Last active October 27, 2017 14:46
bash script for getting the version of all git repos under $1
#!/bin/bash
## thanks to
# https://askubuntu.com/questions/429229/how-to-check-in-a-bash-script-if-passed-argument-is-file-or-directory
# https://stackoverflow.com/questions/5311956/bash-remove-first-directory-component-from-variable-path-of-file
# https://stackoverflow.com/questions/11981716/how-to-quickly-find-all-git-repos-under-a-directory
# https://stackoverflow.com/questions/9612090/how-to-loop-through-file-names-returned-by-find
# https://stackoverflow.com/questions/949314/how-to-retrieve-the-hash-for-the-current-commit-in-git
# https://stackoverflow.com/questions/171550/find-out-which-remote-branch-a-local-branch-is-tracking
# https://stackoverflow.com/questions/4089430/how-can-i-determine-the-url-that-a-local-git-repository-was-originally-cloned-fr
# excellent - https://opensource.com/article/17/6/bash-parameter-expansion
#!/bin/bash
# Copied directly from https://www.drupal.org/node/244924
# Help menu
print_help() {
cat <<-HELP
This script is used to fix permissions of a Drupal installation
you need to provide the following arguments:
curl -O http://downloads.ghostscript.com/public/ghostscript-9.14.tar.gz &&
tar -xzf ghostscript-9.14.tar.gz &&
cd ghostscript-9.14 &&
./configure &&
make install &&
make so &&
cp ghostscript-9.14/sobin/libgs.so.9.14 /usr/lib &&
ln -s /usr/lib/libgs.so.9.14 /usr/lib/libgs.so &&
mkdir -p /etc/ld.so.conf.d/ &&
echo "/usr/lib/libgs.so" > /etc/ld.so.conf.d/libgs.conf &&