Skip to content

Instantly share code, notes, and snippets.

View bencoveney's full-sized avatar
🐿️
Slingin semicolons

Ben Coveney bencoveney

🐿️
Slingin semicolons
View GitHub Profile
@bencoveney
bencoveney / Video_Concatenate.md
Last active July 24, 2022 21:08
Concatenate video files using ffmpeg on windows

Requires ffmpeg installed and in $PATH.

Clip all video files using windows photos (to get *.DRV_TRIM.mp4 files)

Open powershell to the directory with the trimmed videos:

cd  'C:\Users\benco\Videos\Counter-strike  Global Offensive\'
cd ...
@bencoveney
bencoveney / .bashrc
Last active September 6, 2018 12:51
.bashrc
# get current branch in git repo
function parse_git_branch() {
BRANCH=`git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/'`
if [ ! "${BRANCH}" == "" ]
then
echo "[${BRANCH}]"
else
echo ""
fi
}
@bencoveney
bencoveney / settings.json
Last active January 25, 2021 13:31
VSCode settings
{
"telemetry.enableCrashReporter": false,
"telemetry.enableTelemetry": false,
"partialDiff.enableTelemetry": false,
"gitlens.advanced.telemetry.enabled": false,
"diffEditor.ignoreTrimWhitespace": false,
"diffEditor.renderIndicators": false,
"diffEditor.renderSideBySide": true,
"editor.acceptSuggestionOnCommitCharacter": true,
"editor.acceptSuggestionOnEnter": "on",
@bencoveney
bencoveney / .gitconfig
Last active January 25, 2021 13:29
Git config
[diff]
tool = default-difftool
[difftool "default-difftool"]
cmd = code --wait --diff $LOCAL $REMOTE
[core]
editor = code --wait
# Don't paginate if less that a page long
@bencoveney
bencoveney / ConEmu.xml
Last active September 6, 2018 12:54
ConEmu configuration
<?xml version="1.0" encoding="utf-8"?>
<key name="Software">
<key name="ConEmu">
<key name=".Vanilla" modified="2018-09-06 13:54:01" build="180626">
<value name="StartType" type="hex" data="02"/>
<value name="CmdLine" type="string" data=""/>
<value name="StartTasksFile" type="string" data=""/>
<value name="StartTasksName" type="string" data="{Bash::Git bash}"/>
<value name="StartFarFolders" type="hex" data="00"/>
<value name="StartFarEditors" type="hex" data="00"/>
$color-base: #B84231;
$background-base: #212430;
$foreground-base: #E0CF9F;
$amount-of-colors: 10;
.background-darker {
color: darken($background-base, 10%);
}
.background-dark {
@bencoveney
bencoveney / Extensions.txt
Last active August 14, 2017 09:20
Extensions
VSCode
C#
C# XML Documentation Comments
Debugger for Chrome
Document This
Elm
Emoji
Git History Log
IIS Express
@bencoveney
bencoveney / Chocolatey.bat
Created August 8, 2016 07:34
Chocolatey script to install common programs
@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin
cinst 7zip.install -y
cinst ditto -y
cinst greenshot -y
cinst git.install -y
cinst gitextensions -y
cinst conemu -y
cinst nodejs.install -y
cinst paint.net -y
@bencoveney
bencoveney / autoexec.cfg
Last active September 2, 2023 13:43
CSGO configuration
// Mouse
bind "MOUSE1" "+attack"
bind "MOUSE2" "+attack2"
// Movement
bind "a" "+left"
bind "s" "+back"
bind "w" "+forward"
bind "d" "+right"
bind "MWHEELUP" "+jump"
@bencoveney
bencoveney / CSVParser.sql
Created September 29, 2014 12:09
Parsing comma seperated values using SQL CTEs
WITH
/* Provides the seed CSV to parse, can be selected from a table */
CSVRoot AS (
SELECT
'5,8,3,55,2' + ',' AS CSV,
LEN('5,8,3,55,2' + ',') AS Length,
NULL AS Number
),
CSVParser AS (