Skip to content

Instantly share code, notes, and snippets.

View cvbarros's full-sized avatar

Carlos Vitor Barros cvbarros

View GitHub Profile
@g0t4
g0t4 / _resources.md
Last active December 25, 2020 10:09
Resources for TeamCity Getting Started Course
@wouterd
wouterd / Vagrantfile
Last active October 21, 2018 12:17
Vagrant file to setup a 3-server mongo replica set and a script to intialize the mongod cluster
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
$mongoInitScript = <<-"SCRIPT"
YUM_REPO_CONFIG_PATH="/etc/yum.repos.d/mongodb.repo"
tee $YUM_REPO_CONFIG_PATH <<-"EOF"
@xavierdecoster
xavierdecoster / register a myget feed.markdown
Last active July 12, 2022 12:43
Store MyGet credentials in your roaming user profile NuGet.config

Execute the following script using your MyGet [feedUrl] and MyGet [username] , [password] and [apikey]. Run this from a commandline where you have access to nuget.exe (or set the path to your nuget.exe in a system environment variable).

Store credentials in machine-level nuget.config (non-transferable)

nuget setapikey [apikey] -source [feedUrl]
nuget sources add|update -Name [name] -source [feedUrl] -User [username] -pass [password]
@jonnyreeves
jonnyreeves / index.html
Created April 23, 2012 21:38
JavaScript Class Structure using requireJS. The following code shows you how to create a Class definition in one JavaScript file and then import it for use in another; coming from an ActionScript 3 background this (and some of JavaScript specific traits)
<!DOCTYPE html>
<html>
<head>
<script data-main="usage" src="http://requirejs.org/docs/release/1.0.8/comments/require.js"></script>
</head>
<body>
<p>Check your JavaScript console for output!</p>
</body>
</head>
@rberrelleza
rberrelleza / UseServiceBusFromPowershell.ps1
Created March 27, 2012 23:55
Send and receive messages to a Service Bus queue via PowerShell
Import-Module "PATH_TO_Microsoft.ServiceBus.dll"
#Create the required credentials
$tokenProvider = [Microsoft.ServiceBus.TokenProvider]::CreateSharedSecretTokenProvider("owner", "YOUR_ISSUERSECRET")
$namespaceUri = [Microsoft.ServiceBus.ServiceBusEnvironment]::CreateServiceUri("sb", "YOUR_NAMESPACE", "");
$namespaceManager = New-Object Microsoft.ServiceBus.NamespaceManager $namespaceUri,$tokenProvider
#Create a queue
$queue = $namespaceManager.CreateQueue("MyPowershellQueue");