Skip to content

Instantly share code, notes, and snippets.

View vsshs's full-sized avatar

Vaidas Sirtautas vsshs

View GitHub Profile
@vsshs
vsshs / gist:1571891cd261082d474f
Created January 14, 2016 13:50
wlan password
netsh wlan show profile name="INSERT SSID HERE" key=clear
@vsshs
vsshs / git_ignore_only_local
Last active January 12, 2016 13:01
git_ignore_only_local
git update-index --assume-unchanged Web/css/page.css
git update-index --assume-unchanged Web/js/*.js
** check with
git ls-files -v | grep ^[a-z]
@vsshs
vsshs / log Parser Studio.sql
Last active December 18, 2015 14:27
log Parser Studio
SELECT
TO_TIMESTAMP(TO_DATE(date), TO_TIME(time)) AS Timestamp,
sc-status as Status, sc-substatus as Sub-Status, cs-method as Method,
cs-uri-stem as URL, cs-uri-query as Query, time-taken as Time-Taken-ms
FROM '[LOGFILEPATH]'
WHERE
time-taken > 1000
AND TO_DATE(date) = '2015-12-18'
@vsshs
vsshs / prepare-commit-msg
Last active December 11, 2015 12:07 — forked from manderly/prepare-commit-msg
Git hook: Automatically add branch name to the end of every commit message
# Automatically adds branch name to the end of every commit message. Handy for git/JIRA integrations.
# Make a copy of .git/hooks/prepare-commit-msg.sample in your repo and name the file prepare-commit-msg (remove "sample" extension)
# Paste the following into the file, save the file, and try it out in bash
NAME=$(git branch | grep '*' | sed 's/* //')
echo $(cat "$1") " in branch: $NAME" > "$1"
@vsshs
vsshs / newlinevalues.sql
Last active November 13, 2015 15:53
select values with newline symbols
DECLARE @NewLineChar AS CHAR(2) = CHAR(13) + CHAR(10)
SELECT *
FROM <tablename>
WHERE <fieldname> like '%'+@NewLineChar
@vsshs
vsshs / LogViewer pattern for parsing umbraco log files
Last active November 26, 2015 14:22
LogViewer pattern for parsing umbraco log files
%date{yyyy-MM-dd HH:mm:ss,fff} [%Generic] %level %class - %message