Skip to content

Instantly share code, notes, and snippets.

View v2kiran's full-sized avatar

Kiran Reddy v2kiran

View GitHub Profile
@v2kiran
v2kiran / ccmsetup.ps1
Created November 12, 2018 22:05
ccmsetup
$Date = get-date -f ddMMMyyy
# why are we defining these variables ? only define what you use
$FilePath = "C:\Windows\System32\msiexec.exe"
$OS = (Get-WmiObject Win32_OperatingSystem).caption
$Domain = (Get-WmiObject win32_computersystem).Domain
# define every variable before using it
$LogPath = "C:\PostBuild"
New-SelfSignedCertificate -CertStoreLocation Cert:\LocalMachine\My -DnsName "something.something" -FriendlyName "mycert" -NotAfter (Get-Date).AddYears(10)
@v2kiran
v2kiran / vscodesplat.md
Last active October 27, 2018 16:35
vscode splat

Place this in your VSCode profile

Import-Module EditorServicesCommandSuite
Import-EditorCommand -Module EditorServicesCommandSuite

key combo in vscode to invoke splat command

shift + alt + s

// using powershell script --------------------------------------------------- 1
using (PowerShell PowerShellInstance = PowerShell.Create())
{
Collection<PSObject> results = PowerShellInstance.InvokeCommand.InvokeScript("dir");
foreach (PSObject var in results)
{
WriteObject(var.ToString(),false);
}

Keybase proof

I hereby claim:

  • I am v2kiran on github.
  • I am v2kiran (https://keybase.io/v2kiran) on keybase.
  • I have a public key ASBzVDBTbe7LYvigN8Idpxy5CvReaOARLY637I102qRuzgo

To claim this, I am signing this object:

{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0",
"parameters": {
"vnet": {
"type": "string",
"defaultValue": "resource-group/vnet-name"
},
"ipAddress": {
"type": "string",
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0",
"parameters": {
"sku": {
"type": "string",
"defaultValue": "B1"
}
},
"variables": {
Verifying that +kiranreddy is my blockchain ID. https://onename.com/kiranreddy
@v2kiran
v2kiran / Get-BitsService.ps1
Created January 6, 2016 01:20
Gets the bits service using powershell
Get-Service -Name BITS