This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Create a shortcut to this file in Windows for each AnyConnect VPN configuration you need | |
; Each shortcut can have a different host, user, and pass defined (3 command line args) | |
; Usage: AutoHotKey.exe AnyConnect.ahk hostname username password | |
#SingleInstance force | |
if 0 < 3 ; The left side of a non-expression if-statement is always the name of a variable. | |
{ | |
MsgBox This script requires at least 3 incoming parameters but it only received %0%. | |
ExitApp | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param ( | |
[switch]$Relaunched = $false | |
) | |
$ScriptPath = (Get-Variable MyInvocation).Value.MyCommand.Path | |
function StartOperation { | |
Write-Host | |
Write-Host Now attempting to regenerate missing manifest files... | |
Write-Host |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$o=$nothing | |
Get-WindowsOptionalFeature -Online | where State -eq Enabled | %{$o += ("/FeatureName:"+$_.FeatureName+" ")} | |
Write-Host "dism.exe /Online /Enable-Feature $o/All" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use my-database | |
go | |
declare @tableList table (Id int not null primary key identity, DatabaseName varchar(50), SchemaName varchar(50), TableName varchar(50), TableDescription varchar(max)) | |
-- #### CONFIGURATION: | |
-- Which tables to generate the markdown for? | |
insert into @tableList (DatabaseName, SchemaName, TableName, TableDescription) values | |
('my-database', 'dbo', 'Entity', ''), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use varis_p | |
go | |
declare | |
@table varchar(50) = 'dbo.SomeTable' | |
select md from ( | |
-- Row 1 - Headers | |
select | |
-2 as colid, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# REQUIRES PERL.EXE! | |
# | |
# Patch firmware .img files used for Netgear WNDR3800 routers to work with Netgear WNDR3800SW | |
# The SW model routers are specfic to SureWest Communications (ISP from northern CA) | |
# The routers are identical, but require a different header on the .img file. This should work with any | |
# .img file that works with a WNDR3800, including DD-WRT, OpenWRT, and the Netgear factory firmware | |
# | |
## Usage: .\patch3800sw <input img file path> <output img file path> | |
# | |
## Example: .\patch3800sw openwrt-ar71xx-generic-wndr3800-squashfs-factory.img openwrt-wndr3800sw.img |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"basics": { | |
"name": "Adam Plocher", | |
"picture": "https://avatars0.githubusercontent.com/u/1132447?v=4", | |
"label": "Software Developer at Varis LLC", | |
"headline": "A motivated and professional software engineer with over 15 years of experience in the industry", | |
"summary": "Experienced full-stack developer with an appreciation for design patterns.", | |
"website": "http://blog.bitcollectors.com/adam", | |
"yearsOfExperience": 19, | |
"username": "aplocher", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rem UBER COMMAND!! (v2) | |
rem One-liner (technically) - prompts for User, Pass, SecGroup. Includes validation, pre-checks for UAC elevated privileges, checks for user pre-existence and group existence before running, requires a User and Group. | |
cmd /v /c "cls&(net file >nul 2>&1 && ((set /p "u=Enter username: "&&(net user !u! >nul 2>&1&&echo Error: user !u! already exists||(set /p "p=Password: "& set /p "g=Security Group: "&&(net localgroup !g! >nul 2>&1&& (net user !u! !p! /add>nul&&net localgroup !g! /add !u!>nul&&echo SUCCESS: Added new user !u! to group !g!&net user >nul 2>&1)|| (echo Error: specified group does not exist & net user >nul 2>&1))||(echo Error: you must specify a group)))||echo Error: user must not be blank)) || echo Error: you should run as admin)&echo.&echo.&pause" | |
rem Not-so-UBER command (v1) | |
rem One-liner, set the User, Pass, Group in the beginning of the command. No prompts, no validation. Lame. | |
cmd /v /c "set u=myUser&set p=password1&set g=Administrators&cls&net user !u! !p! /add>nul 2> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
net file > NUL 2>&1 | |
if not [%ERRORLEVEL%]==[0] ( | |
echo ERROR - RUN AS ADMIN | |
echo. | |
goto :done | |
) | |
echo Enter the path to the CMDER folder... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
namespace ConsoleApp3 | |
{ | |
// This is a sample Console App written in C# / .NET Core (but should work with .NET Framework). | |
// This will flatten an array structure, recursively, down to the generic type specified (or throw an exception if the input is bad) | |
class Program | |
{ |
NewerOlder