Skip to content

Instantly share code, notes, and snippets.

View alanhoyle's full-sized avatar

Alan Hoyle alanhoyle

View GitHub Profile
@alanhoyle
alanhoyle / keybase.md
Created August 2, 2016 21:38
Keybase Identity file

Keybase proof

I hereby claim:

  • I am alanhoyle on github.
  • I am alanh (https://keybase.io/alanh) on keybase.
  • I have a public key whose fingerprint is D345 0FE1 43B2 5413 7776 CED4 F40A CD1D 04A4 42B9

To claim this, I am signing this object:

FROM store/oracle/database-instantclient:12.2.0.1
#
RUN yum install -y \
gcc \
gzip \
perl \
perl-App-cpanminus \
perl-DBI \
perl-Test-Simple \
FROM store/oracle/database-instantclient:12.2.0.1
#
RUN yum install -y \
gcc \
gzip \
perl \
perl-App-cpanminus \
perl-DBI \
perl-Test-Simple \
@alanhoyle
alanhoyle / Dockerfile-oracle-perl
Last active May 25, 2018 14:36
Dockerfile to build an image for Perl connecting with an Oracle DB via the InstantClient
FROM store/oracle/database-instantclient:12.2.0.1
# I believe one needs to be authenticated to DockerHub to use this image.
# Oracle Linux is RPM based, and these are the requirements for a basic CPAN install for this
RUN yum install -y \
gcc \
gzip \
perl \
perl-App-cpanminus \
perl-DBI \
@alanhoyle
alanhoyle / container_status.sh
Created April 12, 2019 21:01
Simple script to check if the current shell is running in a linux container
#! /usr/bin/env sh
if [[ "$OSTYPE" == "linux-gnu" ]] ; then
if grep -q docker /proc/1/cgroup || test -e /.dockerenv ; then
echo DOCKER ;
elif grep -q lxc /proc/1/cgroup ; then
echo LXC ;
elif test -z ${SINGULARITY_CONTAINER+x} ; then
echo no_container ;
else
@alanhoyle
alanhoyle / vep_for_vcf2maf.sh
Last active November 30, 2020 16:51
Build VEP cache for vcf2maf
# based on https://gist.github.com/ckandoth/5390e3ae4ecf182fa92f6318cfa9fa97
VEP_VER=97
VEP_CACHE=/opt/vep-cache
mkdir -p ${VEP_CACHE}
vep_install -a ap --NO_HTSLIB --NO_TEST --NO_UPDATE -s homo_sapiens -y GRCh38 -c ${VEP_CACHE} --convert --cache_version ${VEP_VER} --PLUGINS LoF
wget https://raw.githubusercontent.com/konradjk/loftee/v0.3-beta/splice_module.pl -O ${VEP_CACHE}/Plugins/splice_module.pl
@alanhoyle
alanhoyle / install_packages_or_die.R
Created February 18, 2021 15:30
Install packages or die function for R
# This function attempts to install a provided list of packages.
# If one of the requested installs fails, it throws an R Error. By default
# This is a useful function to use in a Dockerfile or command line.
# You can put run this at a command line with:
R -e " \
install_packages_or_die <- function (pkgs, repos='http://cran.rstudio.com/') { \
for (l in pkgs) { install.packages(l, dependencies=TRUE, repos=repos); \
if ( ! library(l, character.only=TRUE, logical.return=TRUE) ) { \
@alanhoyle
alanhoyle / # yafc - 2021-12-17_15-53-28.txt
Created December 17, 2021 21:03
yafc on "CentOS Linux release 7.7.1908 (Core)" - Homebrew build logs
Homebrew build logs for yafc on "CentOS Linux release 7.7.1908 (Core)"
Build date: 2021-12-17 15:53:28
@alanhoyle
alanhoyle / # gcc - 2022-01-04_11-14-44.txt
Created January 4, 2022 16:17
gcc on "CentOS Linux release 7.7.1908 (Core)" - Homebrew build logs
Homebrew build logs for gcc on "CentOS Linux release 7.7.1908 (Core)"
Build date: 2022-01-04 11:14:44
@alanhoyle
alanhoyle / etsy_same_tab.js
Last active May 9, 2022 14:09
Force etsy links to open in the same tab/window. (Tampermonkey/greasemonkey/etc)
// ==UserScript==
// @name etsy same window
// @namespace http://tampermonkey.net/
// @version 0.1
// @description stop etsy from opening new tabs for everything
// @author Alan Hoyle
// @match https://www.etsy.com/*
// @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
// @grant none
// ==/UserScript==