Skip to content

Instantly share code, notes, and snippets.

qbik qbikez

Block or report user

Report or block qbikez

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View Transforms.xml
<!-- This task takes in a XDT transform file and transforms it, following any inheritance chain.
There should be at least one base transform for this to work; otherwise just use Microsoft's
regular TransformXml task. -->
<!-- EXAMPLE USAGE:
<TransformXmlHierarchy
Source="source.xml"
Destination="transformed.xml"
TaskDirectory="path/to/directory/of/Microsoft.Web.Publishing.Tasks" />
-->
<UsingTask
View MimeMap.cs
#region Imports
using System;
using System.Collections.Generic;
using System.Linq;
using System.Collections;
using System.Configuration;
using System.IO;
#endregion
@qbikez
qbikez / convert-packagesconfig.ps1
Last active Jan 13, 2016 — forked from rossipedia/convert.ps1
packages.config -> project.json dependencies
View convert-packagesconfig.ps1
(Select-xml '//package' -Path "packages.config" | % { """{0}"": ""{1}""" -f $_.Node.id,$_.Node.version }) -join ",`n"
@qbikez
qbikez / redmine-link.js
Created Feb 1, 2016
Add a "Copy" button to copy redmine ticket subject along with priority and link
View redmine-link.js
@qbikez
qbikez / docker-start.cmd
Created Feb 4, 2016
docker-quickstart-terminal for CMD
View docker-start.cmd
@echo off
REM !/bin/bash
REM trap '[ "$?" -eq 0 ] || read -p "Looks like something went wrong... Press any key to continue..."' EXIT
set VM=default
set DOCKER_MACHINE="./docker-machine.exe"
REM if [ ! -z "$VBOX_MSI_INSTALL_PATH" ]; then
@qbikez
qbikez / color.bat
Created Feb 4, 2016
using colors in cmd console
View color.bat
echo off
REM SETLOCAL EnableDelayedExpansion
for /F "tokens=1,2 delims=#" %%a in ('"prompt #$H#$E# & echo on & for %%b in (1) do rem"') do (
set "DEL=%%a"
)
echo say the name of the colors, don't read
call :ColorText 0a "blue"
call :ColorText 0C "green"
call :ColorText 0b "red"
View color.bat
echo off
REM SETLOCAL EnableDelayedExpansion
for /F "tokens=1,2 delims=#" %%a in ('"prompt #$H#$E# & echo on & for %%b in (1) do rem"') do (
set "DEL=%%a"
)
echo say the name of the colors, don't read
call :ColorText 0a "blue"
call :ColorText 0C "green"
call :ColorText 0b "red"
@qbikez
qbikez / pyvm.cmd
Created Feb 5, 2016
python version manager - a simple version manager with hardcoded paths that can server as a template for future use, Can be used from PS or CMD.
View pyvm.cmd
@echo off
(echo REM pyvm.cmd) > "%TEMP%\_env.cmd"
powershell %~dp0\pyvm.ps1 %*
call "%TEMP%\_env.cmd"
@qbikez
qbikez / nuspec-tools.ps1
Created Feb 7, 2016
powershell helper functions for manipulating nuspec
View nuspec-tools.ps1
function Get-NuspecVersion($nuspec = $null) {
if ([string]::IsNullOrEmpty($nuspec)) {
$nuspec = Get-ChildItem . -Filter *.nuspec | select -First 1
}
$content = Get-Content $nuspec
$verRegex = "<version>(.*)</version>"
[string]$line = $content | where { $_ -match $verRegex } | select -First 1
$ver = $matches[1]
return $ver
}
@qbikez
qbikez / bootstrap.ps1
Last active Aug 25, 2016
boostrap for installing other modules, etc
View bootstrap.ps1
[CmdletBinding()]
param ($path = ".", [switch][bool]$importonly)
function get-envinfo($checkcommands) {
$result = @{}
write-verbose "Powershell version:"
$result.PSVersion = $PSVersionTable.PSVersion
$result.PSVersion | format-table | out-string | write-verbose
You can’t perform that action at this time.