Skip to content

Instantly share code, notes, and snippets.

View mdeguzis's full-sized avatar

Michael T. DeGuzis mdeguzis

View GitHub Profile
@mdeguzis
mdeguzis / steam_console_params.txt
Created February 12, 2023 18:42 — forked from davispuh/steam_console_params.txt
Steam client parameters, consoles commands and variables
-480p - Run tenfoot in 480p rather than 1080p
-720p - Run tenfoot in 720p rather than 1080p
-accesscode -
-all_languages - show longest loc string from any language
-bigpicture - Start in Steam Big Picture mode
-blefw -
-cafeapplaunch - Launch apps in a cyber cafe context
-candidates - Show libjingle candidates for local connection as they are processed
-ccsyntax - Spew details about the localized strings we load
-cef-disable-breakpad - disables breakpad in crash dumps
@mdeguzis
mdeguzis / json2yaml.py
Created May 5, 2018 22:34 — forked from noahcoad/json2yaml.py
Python to convert json to yaml
#!/usr/bin/env python3
# convert json to yaml
# http://pyyaml.org/wiki/PyYAMLDocumentation
# python3 json2yaml.py < ~/code/manpow/moneybug/mbuploader/support/offices.json
# gist https://gist.github.com/noahcoad/46909253a5891af3699580b8f17baba8
import yaml, json, sys
sys.stdout.write(yaml.dump(json.load(sys.stdin)))
@mdeguzis
mdeguzis / gist:fd2093018a5e49e1bdfd0d50738d58e5
Created February 18, 2018 21:53 — forked from jwebcat/gist:5122366
Properly download from github using wget and curl
wget --no-check-certificate --content-disposition https://github.com/joyent/node/tarball/v0.7.1
# --no-check-cerftificate was necessary for me to have wget not puke about https
curl -LJO https://github.com/joyent/node/tarball/v0.7.1
@mdeguzis
mdeguzis / gpg-import-and-export-instructions.md
Created December 17, 2017 00:08 — forked from chrisroos/gpg-import-and-export-instructions.md
Instructions for exporting/importing (backup/restore) GPG keys

Every so often I have to restore my gpg keys and I'm never sure how best to do it. So, I've spent some time playing around with the various ways to export/import (backup/restore) keys.

Method 1

Backup the public and secret keyrings and trust database

cp ~/.gnupg/pubring.gpg /path/to/backups/
cp ~/.gnupg/secring.gpg /path/to/backups/
cp ~/.gnupg/trustdb.gpg /path/to/backups/

or, instead of backing up trustdb...

@mdeguzis
mdeguzis / jenkins-plugins.md
Created November 26, 2017 23:56 — forked from carlessanagustin/jenkins-plugins.md
This is a list of interesting plugins to use with Jenkins

Jenkins plugins

You can read more about each plugin using the SEARCH box at Jenkins homepage.

  • ChuckNorris Plugin: Displays a picture of Chuck Norris (instead of Jenkins the butler) and a random Chuck Norris 'The Programmer' fact on each build page.

Maintenance

  • thinBackup: This plugin simply backs up the global and job specific configurations (not the archive or the workspace).
  • JobConfigHistory Plugin: Saves copies of all job and system configurations.
@mdeguzis
mdeguzis / python-paged-ldap-snippet-2.4.py
Created May 9, 2017 16:13 — forked from mattfahrner/python-paged-ldap-snippet-2.4.py
This snippet allows you to do a Python LDAP search with paged controls. The latest version now supports Python "ldap" 2.4. Many thanks to Ilya Rumyantsev for doing the 2.4 legwork.
#! /usr/bin/python
import sys
import ldap
from ldap.controls import SimplePagedResultsControl
from distutils.version import LooseVersion
# Check if we're using the Python "ldap" 2.4 or greater API
LDAP24API = LooseVersion(ldap.__version__) >= LooseVersion('2.4')
@mdeguzis
mdeguzis / build_cross_gcc
Last active July 23, 2016 13:40 — forked from preshing/build_cross_gcc
A shell script to download packages for, configure, build and install a GCC cross-compiler.
#! /bin/bash
set -e
trap 'previous_command=$this_command; this_command=$BASH_COMMAND' DEBUG
trap 'echo FAILED COMMAND: $previous_command' EXIT
#-------------------------------------------------------------------------------------------
# This script will download packages for, configure, build and install a GCC cross-compiler.
# Customize the variables (INSTALL_PATH, TARGET, etc.) to your liking before running.
# If you get an error and need to resume the script from some point in the middle,
# just delete/comment the preceding lines before running it again.
@mdeguzis
mdeguzis / strapwrap.sh
Created September 30, 2015 19:10 — forked from DazWorrall/strapwrap.sh
Little script to create a minimal ubuntu using debootstrap and bring it up to date
#!/bin/bash
set -e
DEFAULT_PACKAGES=ssh,language-pack-en-base
DEFAULT_COMPONENTS=main,universe
DEBOOTSTRAP=/usr/sbin/debootstrap
DEFAULT_MIRROR=http://archive.ubuntu.com/ubuntu
DEFAULT_VARIANT=minbase
MIRROR=${STRAP_MIRROR:-$DEFAULT_MIRROR}
ROOTFS=$1
@mdeguzis
mdeguzis / install-vmware-certs.sh
Last active September 20, 2015 16:51 — forked from tonejito/install-vmware-certs.sh
install-vmware-certs.sh - Fix VMware cert error by installing CA certificate into ssl capath
#!/bin/bash
# install certificate into CApath
# I use relative paths to keep compatibility with chroot'd environments
cd /etc/ssl/certs/
ln -vsf ../../../usr/lib/vmware-ovftool/certs/cacert.pem vmware.pem
# Regenerate openssl CA database
c_rehash > /dev/null
@mdeguzis
mdeguzis / clients.md
Last active September 9, 2015 13:53 — forked from defunkt/clients.md
A list of Gist clients.

Gist Clients

Want to create a Gist from your editor, the command line, or the Services menu? Here's how.

Editor Support