This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "===================================================================" | |
echo | |
echo "Installs Jenkins & Open-JDK 8" | |
echo "You may be prompted for root credentials to complete the install." | |
echo | |
echo "===================================================================" | |
set -o nounset # unset variables are errors |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o nounset # unset variables are errors | |
SCRIPTVERSION="2019.01.29-Debian" | |
SCRIPTNAME="setup-jenkins-nginx.sh" | |
SCRIPTFULLNAME="$0" | |
PORT='8080' | |
WEBNAME='jenkins.yourdomain' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# https://medium.com/@porteneuve/mastering-git-submodules-34c65e940407#.3o6drt47o | |
# http://blogs.atlassian.com/2013/03/git-submodules-workflows-tips/#scenarios | |
# http://stackoverflow.com/questions/2144406/git-shallow-submodules | |
# ----------------- | |
# INSTALL AND SETUP | |
# ----------------- | |
# https://github.com/bobthecow/git-flow-completion/wiki/Install-Bash-git-completion |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o nounset # unset variables are errors | |
SCRIPTVERSION="2019.01.25-Debian" | |
SCRIPTNAME="install-salt-minion.sh" | |
SCRIPTFULLNAME="$0" | |
SALTMASTER='192.168.56.101' #IP of Salt-master | |
echoerror() { printf "\033[1;31m * ERROR\033[0m: %s\\n" "$@" 1>&2; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Nginx installer script - Ruby On Rails example | |
# | |
# Pre-req: | |
# * Ubuntu Bionic (18.04) flavored distro | |
# * Script must be executed under the account of the web admininstrator | |
# * linux-devel-setup.sh - https://gist.github.com/WillSams/f17427b5a4f5bccc23d6efe1389b33ca | |
# * mongodb-setup.sh - https://gist.github.com/WillSams/3588b69c805acf07ccb278c55fd91302 | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o nounset # unset variables are errors | |
SCRIPTVERSION="2019.01.25-Debian" | |
SCRIPTNAME="install-salt-master.sh" | |
SCRIPTFULLNAME="$0" | |
BROADCAST='192.168.56.1/24' #local network broadcast IP & subnet | |
echoerror() { printf "\033[1;31m * ERROR\033[0m: %s\\n" "$@" 1>&2; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o nounset # unset variables are errors | |
SCRIPTVERSION="2018.10.09-Debian" | |
SCRIPTNAME="create-dotnetcore-example.sh" | |
SCRIPTFULLNAME="$0" | |
SOLUTIONNAME=Northwind | |
API=$SOLUTIONNAME.Api |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set -o nounset # unset variables are errors | |
__ScriptVersion="2018.02.19" | |
__ScriptName="bowling-ruby_tdd_kata-Debian.sh" | |
__ScriptFullName="$0" | |
if [ -d $HOME/.rvm ]; then | |
echo "RVM /w Ruby is already installed on your machine." | |
else | |
echo "********************** RVM & RUBY INSTALL ************************" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "===================================================================" | |
echo " This script can be executed under Linux or Windows (using MSys2) " | |
echo " Modify GENDEV variable to fit your toolchain. " | |
echo | |
echo " Linux toolchain: " | |
echo " https://gist.github.com/WillSams/c4cbf6235b467d8b595693969342237e " | |
echo | |
echo " Windows toolchain: " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ============================================================================== | |
# 1 - Powershell program to determine if any two integers in array sum to given integer | |
# ============================================================================== | |
echo '$myArray = @{} | |
class Algorithm { | |
#Brute force solution, O(n^2) time complexity | |
[bool] TwoIntegersSumToTarget([int[]] $arr, [int] $target) { | |
$numElements = $arr.length | |
for ([int] $outer = 0; $outer -lt $numElements; $outer++) { |