Skip to content

Instantly share code, notes, and snippets.

View wcoastsands's full-sized avatar
😎
Godot? Don't mind if I g'do!

wcoastsands

😎
Godot? Don't mind if I g'do!
  • 08:50 (UTC -07:00)
View GitHub Profile
@wcoastsands
wcoastsands / sort-files.sh
Last active January 10, 2024 06:25
Sorts files into subfolders
#!/bin/bash
# Sorts files into subfolders by date, or by file extension.
#
# TODO: Set the permissions on this file to 700.
# chmod 700 sort-files.sh
# TODO: Create symlinks for use with this script.
# ln -s sort-files.sh sort-files
# File extension (optional parameter).
EXT="${1^^}"
@wcoastsands
wcoastsands / ssh-helper.sh
Last active September 27, 2023 19:16
Helper utility for SSH and SFTP
#!/bin/bash
# Provides login shortcuts via SSH and SFTP.
#
# TODO: Set the permissions on this file to 700.
# chmod 700 ssh-helper.sh
# TODO: Create symlinks for use with this script.
# ln -s ssh-helper.sh ssh
# ln -s ssh-helper.sh sftp
echo "Using the SSH Helper..."
@wcoastsands
wcoastsands / callback.php
Last active July 28, 2023 22:54
Unity Ads S2S Redeem Callback Example
<?php # callback.php (PHP 5) - Evaluates the Unity Ads S2S Redeem Callback.
//-----------------------------------------------------------------------------
// Each callback should contain the following parameters in the query string:
// pid -- product/game ID specified as part of the base callback URL
// sid -- user ID set through the Unity Ads SDK
// oid -- offer ID unique to each callback
// hmac -- HDMAC-MD5 hash of the query string
//-----------------------------------------------------------------------------
@wcoastsands
wcoastsands / MovePHD2Logs.bat
Last active January 5, 2023 19:29
Move PHD2 log files to avoid deletion
@echo off
:: MovePHD2Logs.bat
:: Written by Nikkolai Davenport (https://github.com/wcoastsands).
:: Move PHD2 log files into subfolders to avoid automatic deletion.
setlocal
set "Title=MovePHD2Logs"
set "Version=1.1.9"
set "Author=Nikkolai Davenport (https://github.com/wcoastsands)"
set "Heading=%Title% (v%Version%)"
@wcoastsands
wcoastsands / BuildManifestObject.cs
Last active December 3, 2022 00:42
BuildManifestObject stub for use with pre-export methods in Unity Cloud Build
#if !UNITY_CLOUD_BUILD
using System.Collections.Generic;
namespace UnityEngine.CloudBuild
{
/// <summary>
/// A stub of the <see cref="T:UnityEngine.CloudBuild.BuildManifestObject"/> class,
/// available only on Unity Cloud Build servers.
/// <para>Pre export methods must take a single parameter of this type in order for the
/// method to be called prior to building a project in Unity Cloud Build.
@wcoastsands
wcoastsands / config-wacom.sh
Created November 2, 2022 06:36
Configure Wacom Bamboo Pen and Touch
#!/bin/bash
# Configure Wacom Bamboo Pen and Touch (CTH-460)
#
# Device List:
# Wacom Bamboo 2FG 4x5 Pen stylus
# Wacom Bamboo 2FG 4x5 Finger touch
# Wacom Bamboo 2FG 4x5 Pad pad
# Wacom Bamboo 2FG 4x5 Pen eraser
#
# Express Key Button IDs (left side):
@wcoastsands
wcoastsands / 01_DOSBoxGames.md
Last active September 22, 2022 21:05
DOSBox Games

DOSBox Games

A collection of DOSBox games, config files, and a launcher style bash script.

Unpacking

This collection of DOSBox games is distributed as a compressed zip archive.

To install, first locate or create a destination directory for the games collection. Then unzip the contents of the archive to the destination directory, and create a symlink to the launcher script in a common path directory.

@wcoastsands
wcoastsands / ReaperInstallGuide.md
Last active September 22, 2022 18:06
Installing Reaper on Ubuntu 22.04 LTS

Installing Reaper on Ubuntu 22.04 LTS

The best way to install the Reaper digital audio workstation on Linux is to install the included script. You’ll have to download the Reaper DAW program files from the internet to start.

After downloading the latest Reaper DAW files to your computer, you’ll have to extract the contents of the TarXZ archive using the tar command.

tar xvf reaper646_linux_x86_64.tar.xz

Once the extraction process is complete, you must create a folder named Reaper in your home directory using the mkdir command.

@wcoastsands
wcoastsands / Joysticks.ini
Last active June 16, 2022 06:44
Celestron NexRemote Joystick Mapping
[JOYSTICKS]
[JOYSTICK]
Name = Controller (XBOX 360 For Windows)
; This is the Xbox 360 USB Wired Controller for Windows
Button1 = Enter ;Button A (bottom action)
Button2 = Undo ;Button B (right action)
Button3 = MenuDown ;Button X (left action)
Button4 = MenuUp ;Button Y (top action)
Button5 = RateDown ;Button LB (left shoulder)
@wcoastsands
wcoastsands / rpi-thermal-monitor.sh
Last active March 30, 2022 20:20
Thermal bench test for Raspberry Pi
#!/bin/bash
SOURCE="${BASH_SOURCE[0]}"
# Resolve $SOURCE until the file is no longer a symlink.
while [ -h "$SOURCE" ]; do
DIR="$( cd -P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )"
SOURCE="$(readlink "$SOURCE")"
[[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
# If $SOURCE was a relative symlink, we need to resolve it
# relative to the path where the symlink file was located.
done