A simple powershell script to clean up local branches that have been merged to main:
git branch --merged main | Foreach-object { if($_.SubString(0,1) -ne '*'){ git branch -d $_.SubString(2);} }
#requires -version 5.1 | |
<# | |
Based on a function from https://gist.github.com/dhmacher/2203582502c7ab13015db8f52e94da45 | |
You need an access token that has at least write access to your status | |
* go to settings -> Development | |
* Click "New Application" | |
* Enter a name |
Many distributed NoSQL databases (and Cosmos DB specifically) are unique in their ability to scale to massive size but still maintain millisecond request latencies and also remain highly efficient in performance AND cost. However, achieving this takes knowledge. Finding an optimal design also requires some trial and error too as you will have to test at scale to validate your design will scale.
For those who are new to distributed NoSQL databases (and especially if you have years of experience in designing and using relational databases) and want to undestand how to design a database for scale and performance we recommended consuming this content below to learn some of these key concepts and techniques before getting too far in your design.
Generally speaking, deep undestanding of relational database design will not help in this regard. In fact, in most cases applying relational concepts and techniques are anti-patterns here. Additionally, some of the concepts are unintuitive.
We hope you find this conte
# updated to remove my really ugly first attempt, based on awesome feedback provided. | |
$web = @{ | |
RedirectUris = "https://localhost:5001/signin-oidc" | |
ImplicitGrantSettings = @{ EnableIdTokenIssuance = $true } | |
} | |
$createAppParams = @{ | |
DisplayName = "AspNetWebApp" | |
Web = $web |
$userPath = $env:USERPROFILE | |
$pathExclusions = New-Object System.Collections.ArrayList | |
$processExclusions = New-Object System.Collections.ArrayList | |
$pathExclusions.Add('C:\Windows\Microsoft.NET') > $null | |
$pathExclusions.Add('C:\Windows\assembly') > $null | |
$pathExclusions.Add($userPath + '\AppData\Local\Microsoft\VisualStudio') > $null | |
$pathExclusions.Add('C:\ProgramData\Microsoft\VisualStudio\Packages') > $null | |
$pathExclusions.Add('C:\Program Files (x86)\MSBuild') > $null | |
$pathExclusions.Add('C:\Program Files (x86)\Microsoft Visual Studio 14.0') > $null |
var compilation = CSharpCompilation.Create("C") | |
.AddReferences(MetadataReference.CreateFromFile(pathToAssembly)); | |
foreach (var type in | |
from assemblySymbol in compilation.SourceModule.ReferencedAssemblySymbols | |
from module in assemblySymbol.Modules | |
from n in module.GlobalNamespace.GetMembers() | |
where n.IsNamespace | |
from type in n.GetTypeMembers() | |
select type) |
On October 30, 2023, the Throat Punch List turned 10! In honor of that occasion, I'm putting some old favorites back on the list!
namespace ConsoleApplication2 | |
{ | |
using System; | |
using System.Configuration; | |
using Microsoft.ServiceBus; | |
using Microsoft.ServiceBus.Messaging; | |
class Program | |
{ | |
static void Main(string[] args) |