Skip to content

Instantly share code, notes, and snippets.

Setting, DefaultValue, INIValue, CurrentValue, Origin
sScreenShotBaseName:Display, <unimplemented>, <unimplemented>, <unimplemented>, INI
sScreenShotFolderName:Display, <unimplemented>, <unimplemented>, <unimplemented>, INI
sRuntimeLODDatabasePath:LODManager, <unimplemented>, <unimplemented>, <unimplemented>, INI
strPluginsFileHeader:General, <unimplemented>, <unimplemented>, <unimplemented>, INI
sLanguage:General, <unimplemented>, <unimplemented>, <unimplemented>, INI
sFailureMessage:LANGUAGE, <unimplemented>, <unimplemented>, <unimplemented>, INI
sResourcePrefixList:Archive, <unimplemented>, <unimplemented>, <unimplemented>, INI
sDLCDefaultVoiceSuffix:Archive, <unimplemented>, <unimplemented>, <unimplemented>, INI
sLocalMasterPath:General, <unimplemented>, <unimplemented>, <unimplemented>, INI
Setting, DefaultValue, INIValue, CurrentValue, Origin
sScreenShotBaseName:Display, <unimplemented>, <unimplemented>, <unimplemented>, INI
sScreenShotFolderName:Display, <unimplemented>, <unimplemented>, <unimplemented>, INI
sRuntimeLODDatabasePath:LODManager, <unimplemented>, <unimplemented>, <unimplemented>, INI
strPluginsFileHeader:General, <unimplemented>, <unimplemented>, <unimplemented>, INI
sLanguage:General, <unimplemented>, <unimplemented>, <unimplemented>, INI
sFailureMessage:LANGUAGE, <unimplemented>, <unimplemented>, <unimplemented>, INI
sResourcePrefixList:Archive, <unimplemented>, <unimplemented>, <unimplemented>, INI
sDLCDefaultVoiceSuffix:Archive, <unimplemented>, <unimplemented>, <unimplemented>, INI
sLocalMasterPath:General, <unimplemented>, <unimplemented>, <unimplemented>, INI
@DannyBen
DannyBen / levenshtein.sh
Created August 14, 2022 21:01 — forked from benpitman/levenshtein.sh
Bash function to calculate the levenshtein distance between two strings
#!/usr/bin/env bash
levenshtein ()
{
local -r -- target=$1
local -r -- given=$2
local -r -- targetLength=${#target}
local -r -- givenLength=${#given}
local -- alt
local -- cost
@DannyBen
DannyBen / tmux.md
Created May 13, 2022 20:56 — forked from andreyvit/tmux.md
tmux cheatsheet

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

@DannyBen
DannyBen / cryptokitties.sol
Created September 12, 2021 17:43 — forked from arpit/cryptokitties.sol
Cryptokitties Contract from the Eth blockchain
pragma solidity ^0.4.11;
/**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/
contract Ownable {
address public owner;
@DannyBen
DannyBen / stub.bash
Created December 9, 2019 13:19 — forked from jimeh/stub.bash
Shell script helpers to stub and restore bash shell functions/commands in tests.
# Stub commands printing it's name and arguments to STDOUT or STDERR.
stub() {
local cmd="$1"
if [ "$2" == "STDERR" ]; then local redirect=" 1>&2"; fi
if [[ "$(type "$cmd" | head -1)" == *"is a function" ]]; then
local source="$(type "$cmd" | tail -n +2)"
source="${source/$cmd/original_${cmd}}"
eval "$source"
fi
@DannyBen
DannyBen / asn
Last active August 16, 2023 16:35 — forked from nitefood/README.md
ASN/IP/Route/hostname command line lookup tool to map any network to the corresponding ASN and prefix
#!/usr/bin/env bash
##############################################################################
# ----------------------------------------------------------------------
# ASN/IPv4/Prefix lookup tool. Uses Team Cymru's whois service for data.
# ----------------------------------------------------------------------
# example usage:
# asn <ASnumber> -- to lookup matching ASN data. Supports "as123" and
# "123" formats (case insensitive)
# asn <IP.AD.DR.ESS> -- to lookup matching route and ASN data
@DannyBen
DannyBen / spec_helper.rb
Last active February 15, 2018 21:40 — forked from nu7hatch/spec_helper.rb
Testing standard input with RSpec
module Helpers
# Replace standard input with faked one StringIO.
def stdin_send(*args)
begin
$stdin = StringIO.new
$stdin.puts(args.shift) until args.empty?
$stdin.rewind
yield
ensure
$stdin = STDIN
@DannyBen
DannyBen / apache_bench.sh
Created October 10, 2015 17:49 — forked from seyhunak/apache_bench.sh
Rails - Apache Bench - Load Testing (if Devise Sign-in Required)
1.
LOGIN_PAGE=http://localhost/users/sign_in
curl --cookie-jar cookie_file $LOGIN_PAGE | grep csrf-token
2.
<meta content="csrf-token" name="csrf-token" />
@DannyBen
DannyBen / gh-pages-deploy.md
Last active August 29, 2015 14:25 — forked from cobyism/gh-pages-deploy.md
Deploy to `gh-pages` from a `dist` folder on the master branch. Useful for use with [yeoman](http://yeoman.io).

Deploying a subfolder to GitHub Pages

Sometimes you want to have a subdirectory on the master branch be the root directory of a repository’s gh-pages branch. This is useful for things like sites developed with Yeoman, or if you have a Jekyll site contained in the master branch alongside the rest of your code.

For the sake of this example, let’s pretend the subfolder containing your site is named dist.

Step 1

Remove the dist directory from the project’s .gitignore file (it’s ignored by default by Yeoman).