Skip to content

Instantly share code, notes, and snippets.

@scottlinux
scottlinux / cpustatus.sh
Last active March 7, 2016 19:32 — forked from ecampidoglio/cpustatus.sh
A Bash script that prints the current state of the CPU on a Raspberry Pi. It displays variables like temperature, voltage and speed. (Modified for Arch Linux Arm)
#!/bin/bash
# cpustatus
#
# Prints the current state of the CPU like temperature, voltage and speed.
# The temperature is reported in degrees Celsius (C) while
# the CPU speed is calculated in megahertz (MHz).
function convert_to_MHz {
let value=$1/1000
echo "$value"
@scottlinux
scottlinux / config.txt
Created June 11, 2016 17:41
Raspberry Pi 2 overclock settings
gpu_mem=16
arm_freq=1000
sdram_freq=500
core_freq=500
over_voltage=2
temp_limit=80
initial_turbo = 30
@scottlinux
scottlinux / bucketcopy.sh
Created April 13, 2017 14:43
Copy list of AWS S3 buckets into one S3 bucket
#!/usr/bin/env bash
# Copy contents of many s3 buckets into a single
# archive bucket
#
# Run via an ec2 instance
set -e
set +x
@scottlinux
scottlinux / backblaze b2 backup script
Last active November 6, 2019 23:12
Backup script for backblaze b2
#!/usr/bin/env bash
#
# Backup selected directories to a Backblaze B2 bucket
#
# Example daily cron:
# @daily /usr/local/bin/b2backup >/dev/null
#
# Account creds
id=xxxxxxxxxx
@scottlinux
scottlinux / delete-stuck-openstack-instance.sh
Created January 9, 2020 19:51
Delete openstack instance stuck in error state
#!/usr/bin/env bash
#
# Delete RHOS instance stuck in error state
#
set -e
# prompt for instance ID to delete
printf "\n"
#!/bin/sh
showHelp() {
cat <<EOF
This script requires 2 or 3 arguments exactly.
"${0}" <redhat username> <redhat password> [<redhat release>]
examples:
"${0}" user1 passw0rd! 7Server
"${0}" user2 pAssw@rd
By default the omission of the release version will default to 7Server being set.
@scottlinux
scottlinux / config.txt
Created July 10, 2016 00:07
Raspberry Pi 3 overclock
# Pi3 overclock! https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=138123
gpu_mem=16 # set as desired
dtparam=sd_overclock=100
arm_freq=1300
core_freq=500
over_voltage=4
sdram_freq=575
sdram_schmoo=0x02000020
over_voltage_sdram_p=6
over_voltage_sdram_i=4
@scottlinux
scottlinux / update_retroarch_cores.sh
Created December 10, 2020 15:32
Update retroarch cores to latest - Fedora Linux
#!/usr/bin/env bash
wget -m -np -nd -c -R "index.html*" "https://buildbot.libretro.com/nightly/linux/x86_64/latest/" -P ~/.config/retroarch/cores && unzip ~/.config/retroarch/cores/'*.zip' && rm ~/.config/retroarch/cores/*.zip
@scottlinux
scottlinux / mf-install-helper.sh
Last active October 22, 2023 11:58 — forked from AnonymerNiklasistanonym/mf_install_helper.sh
Helping script that automatically installs the Media Foundation workaround for Wine (https://github.com/z0z0z/mf-install) to the latest Proton Version
#!/usr/bin/env bash
#
rm -rf mf-install
git clone --depth=1 https://github.com/z0z0z/mf-install.git
cd mf-install
GRIS_STEAM_ID=683320
PUMMEL_PARTY_STEAM_ID=880940
# Select which game should be updated