Skip to content

Instantly share code, notes, and snippets.

View rbellamy's full-sized avatar

Richard Bellamy rbellamy

  • Ford Pro
  • Cotati, CA
View GitHub Profile
@rbellamy
rbellamy / gnome.sh
Created March 30, 2015 03:59
gnome 3.6.2
# GNOME 3.6.2
# stole fair and square from https://gist.github.com/musinsky/2402448#file-gnome-sh
gsettings set org.gnome.desktop.default-applications.terminal exec 'gnome-terminal --geometry=96x24+0-0'
gsettings set org.gnome.desktop.default-applications.terminal exec-arg '-x'
gsettings set org.gnome.desktop.background picture-options 'none'
gsettings set org.gnome.desktop.background color-shading-type 'vertical'
gsettings set org.gnome.desktop.background primary-color '#3C78B4' # (Red: 60 Green: 120 Blue: 180)
gsettings set org.gnome.desktop.background secondary-color '#1E3C5A' # (Red: 30 Green: 60 Blue: 90)
@rbellamy
rbellamy / install-vagrant-libvirt.sh
Created April 3, 2015 17:33
How to install vagrant-libvirt on ArchLinux so that ruby-libvirt isn't borked
# in case it's already installled
vagrant plugin uninstall vagrant-libvirt
# vagrant's copy of curl prevents the proper installation of ruby-libvirt
sudo mv /opt/vagrant/embedded/lib/libcurl.so{,.backup}
sudo mv /opt/vagrant/embedded/lib/libcurl.so.4{,.backup}
sudo mv /opt/vagrant/embedded/lib/libcurl.so.4.3.0{,.backup}
sudo mv /opt/vagrant/embedded/lib/pkgconfig/libcurl.pc{,.backup}
CONFIGURE_ARGS="with-libvirt-include=/usr/include/libvirt with-libvirt-lib=/usr/lib" vagrant plugin install vagrant-libvirt
@rbellamy
rbellamy / 51-kensington-expert-mouse.conf
Last active March 25, 2020 16:16
Kensington Expert Mouse Trackball - ButtonMapping
# Kensington Expert Mouse Trackball
# Run "xinput" to see the id and what it's called
#
#
# Run "xev|grep Button -A 3" to see the actual mappings
# Bottom Right - 1
# Bottom Left - 3
# Upper Left - 2
# Upper Right - 8
@rbellamy
rbellamy / ipmitool-sensor-list.md
Last active August 29, 2015 14:19
IPMI troubleshooting and threshold configuration

Run the command

$ ipmitool sensor list all  
CPU1 Temp        | 0x0        | discrete   | 0x0000| na        | na        | na        | na        | na        | na        
CPU2 Temp        | 0x0        | discrete   | 0x0000| na        | na        | na        | na        | na        | na        
System Temp      | 38.000     | degrees C  | ok    | -9.000    | -7.000    | -5.000    | 75.000    | 77.000    | 79.000    
CPU1 Vcore       | 0.976      | Volts      | ok    | 0.808     | 0.816     | 0.824     | 1.432     | 1.440     | 1.448     
CPU2 Vcore       | 0.920      | Volts      | ok    | 0.808     | 0.816     | 0.824     | 1.432     | 1.440     | 1.448     
CPU1 DIMM        | 1.520      | Volts      | ok    | 1.288     | 1.296     | 1.304     | 1.656     | 1.664     | 1.672     
@rbellamy
rbellamy / schema_compare.sql
Created May 28, 2015 21:29
Oracle schema comparison
REM
REM schema_compare.sql
REM ===================
REM
REM This script is provided by Database Specialists, Inc.
REM (http://www.dbspecialists.com) for individual use and not for sale.
REM Database Specialists, Inc. does not warrant the script in any way
REM and will not be responsible for any loss arising out of its use.
REM
REM Your feedback is welcome! Please send your comments about this script
@rbellamy
rbellamy / group-perms.py
Created September 20, 2015 23:10
BitBucket to GitHub
#! /usr/bin/env python
from sys import exit, stderr
from subprocess import Popen, PIPE
import json
import urllib
# Run this on the command line to get an access token
# paste in your OAuth consumer key and secret
# paste in your username and password
#!/usr/bin/env bash
size=1024 # MB
mount_point=$HOME/tmp
name=$(basename "$mount_point")
usage() {
echo "usage: $(basename "$0") [mount | umount | remount | check | orphan]" \
"(default: mount)" >&2
}
@rbellamy
rbellamy / bitbucket-to-github.rb
Last active October 8, 2024 14:45
Bulk import Bitbucket repos to Github
#!/usr/bin/env ruby
require 'fileutils'
# Originally -- Dave Deriso -- [email protected]
# Contributor -- G. Richard Bellamy -- [email protected]
# If you contribute, put your name here!
# To get your team ID:
# 1. Go to your GitHub profile, select 'Personal Access Tokens', and create an Access token
# 2. curl -H "Authorization: token <very-long-access-token>" https://api.github.com/orgs/<org-name>/teams
# 3. Find the team name, and grabulate the Team ID
@rbellamy
rbellamy / compaudit-permission-fix.sh
Last active November 26, 2015 22:04
complete:13: command not found: compdef
#from https://github.com/robbyrussell/oh-my-zsh/issues/630#issuecomment-70291622
#This will perform chmod g-w for each file returned by compaudit to remove write access for group
compaudit | xargs -I % chmod g-w "%"
#This will perform chown to current user (Windows and Linux) for each file returned by compaudit
compaudit | xargs -I % chown $USER "%"
#Remove all dump files (which normally speed up initialization)
rm ~/.config/zsh/.zcompdump*
#Regenerate completions file
compinit
@rbellamy
rbellamy / 0001-Honor-IDEA_JDK-set-by-environment.patch
Created January 1, 2016 01:30
intellij-idea-ultimate-edition AUR patch
From 98898a025749769615ea53bcd0271174c62ca89d Mon Sep 17 00:00:00 2001
From: "G. Richard Bellamy" <[email protected]>
Date: Thu, 31 Dec 2015 15:03:57 -0800
Subject: [PATCH] Honor IDEA_JDK set by environment
---
PKGBUILD | 5 ++---
intellijidea.sh | 3 ++-
2 files changed, 4 insertions(+), 4 deletions(-)