Skip to content

Instantly share code, notes, and snippets.

View RandyMcMillan's full-sized avatar
🛰️
Those who know - do not speak of it.

@RandyMcMillan RandyMcMillan

🛰️
Those who know - do not speak of it.
View GitHub Profile
#!/bin/bash
################################
# OS X Install ISO Creater #
# #
# Author: shela #
################################
#######################################
# Declarations
@RandyMcMillan
RandyMcMillan / disable.sh
Last active February 25, 2020 05:34
Disable bunch of #$!@ in Catalina
#!/bin/bash
# IMPORTANT: Don't forget to logout from your Apple ID in the settings before running it!
# IMPORTANT: You will need to run this script from Recovery. In fact, macOS Catalina brings read-only filesystem which prevent this script from working from the main OS.
# This script needs to be run from the volume you wish to use.
# E.g. run it like this: cd /Volumes/Macintosh\ HD && sh /Volumes/Macintosh\ HD/Users/sabri/Desktop/disable.sh
# WARNING: It might disable things that you may not like. Please double check the services in the TODISABLE vars.
# Get active services: launchctl list | grep -v "\-\t0"
# Find a service: grep -lR [service] /System/Library/Launch* /Library/Launch* ~/Library/LaunchAgents
@RandyMcMillan
RandyMcMillan / howto_create_online_radio_macos_sierra.txt
Created March 5, 2020 20:51 — forked from dmpanch/howto_create_online_radio_macos_sierra.txt
How to create internet radio on MacOS Sierra 10.12
All actions are performed in Terminal.app.
1. Install Homebrew http://brew.sh/
2. Install Jack (route audio tool) http://jackaudio.org/. Current stable version from official website doesn't work with
MacOS Sierra (I use 10.12.3) so you need to download beta version from there https://yadi.sk/d/JwT10b7v3Dm5yy.
After installing reboot your computer.
3. Install Darkice (audio streamer) via brew.
@RandyMcMillan
RandyMcMillan / README.md
Created June 24, 2020 08:26 — forked from joyrexus/README.md
collapsible markdown

collapsible markdown?

CLICK ME

yes, even hidden code blocks!

print("hello world!")
#!/usr/bin/env ruby
# Usage: githubify <gemspec_file> [username]
# Requires: github.name to be set for the current git project or [username] to be specified
# Result: creates/overwrites a file named <username>-<gemspec_file> and updates the s.name in there have the same project name format.
#
# Author: Wes Oldenbeuving
# E-mail: narnach@gmail.com
# License: MIT-LICENSE
class String
@RandyMcMillan
RandyMcMillan / mingw-w64-4.0.4-osx10.11.2.sh
Created April 19, 2021 03:08 — forked from cosmo0920/mingw-w64-4.0.4-osx10.11.2.sh
Script to install a Mingw-w64 Cross-Compiler Suite on Mac OS X 10.11.2
#!/bin/sh
# dependencies
echo "Installing dependencies via Homebrew (http://brew.sh)"
ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"
brew update
brew tap homebrew/versions
@RandyMcMillan
RandyMcMillan / bitcoin-pay.rb
Created July 14, 2021 06:07 — forked from Sjors/bitcoin-pay.rb
This script demonstrates how a bitcoin transaction is created and signed. Just pass in your own address and private key and it will prepare a transaction for you. You can then copy & paste that transaction into a webservice like Blockchain to send it. I wrote this mostly to understand better how it works. I sometimes had to "cheat" and look at t…
#!/usr/bin/env ruby
require 'open-uri'
require 'JSON'
require 'digest/sha2'
require 'pry'
require 'bigdecimal'
require 'bitcoin' # Because I need to cheat every now and then
# Usage:
# gem install pry json ffi ruby-bitcoin
@RandyMcMillan
RandyMcMillan / p618.py
Created July 28, 2021 18:30 — forked from igorvanloo/p618.py
Problem 618
def compute(limit):
d = [1] + [0] * limit
primes = eulerlib.primes(limit)
mod = 10**9
Fibonnaci_numbers = [2,3,5,8,13,21,34,55,89,144,233,377,610,987,1597,2584,4181,6765,10946,17711,28657,46368]
for p in primes:
for i in range(p,limit+1):
d[i] += (p*d[i-p] % mod)
@RandyMcMillan
RandyMcMillan / setup-cross-cc.sh
Last active November 18, 2022 02:09 — forked from xentec/setup-cross-cc.sh
Alpine Linux cross-compiler setup script
#!/bin/sh
CTARGET="$1"
if [ -z "$CTARGET" ]; then
program=$(basename $0)
echo "usage: $program TARGET_ARCH"
return 1
fi
# get abuild configurables
@RandyMcMillan
RandyMcMillan / bitcoind-ubuntu-install
Created November 14, 2021 06:23 — forked from rjmacarthy/bitcoind-ubuntu-install
Install Bitcoind Ubuntu
** Add repository and install bitcoind **
sudo apt-get install build-essential
sudo apt-get install libtool autotools-dev autoconf
sudo apt-get install libssl-dev
sudo apt-get install libboost-all-dev
sudo add-apt-repository ppa:bitcoin/bitcoin
sudo apt-get update
sudo apt-get install bitcoind
mkdir ~/.bitcoin/ && cd ~/.bitcoin/