A collection of powerful productivity tools all within an extendable launcher.
Graphically shows the disk usage within a file system.
A collection of powerful productivity tools all within an extendable launcher.
Graphically shows the disk usage within a file system.
/// <summary> | |
/// Async edition of <see cref="Lazy{T}"/>. | |
/// </summary> | |
/// <typeparam name="T">The type of the lazily initialized value</typeparam> | |
public class AsyncLazy<T> : Lazy<Task<T>> | |
{ | |
public AsyncLazy(Func<T> valueFactory) | |
: base(() => Task.Run(valueFactory)) { } | |
public AsyncLazy(Func<Task<T>> asyncValueFactory) |
# This will allow the job to only execute for Pull Request builds | |
condition: eq(variables['Build.Reason'], 'PullRequest') | |
steps: | |
- task: UseDotNet@2 | |
displayName: 'Use .Net Core runtime 3.1.x' | |
inputs: | |
packageType: runtime | |
version: 3.1.x |
using System; | |
using System.Text; | |
public class Program | |
{ | |
public static void Main() | |
{ | |
var password = "SuperSecretLongPassword"; | |
var bytes = Encoding.UTF8.GetBytes(password); | |
var base64 = Convert.ToBase64String(bytes); |
function Get-WeatherForecast { | |
<# | |
.SYNOPSIS | |
Gets the weather forecast for a location of choice. | |
.DESCRIPTION | |
Displays the weather forecast for a location of choice, directly in | |
the terminal. Powered by wttr.in. | |
.NOTES | |
Author: Tormod Fjeldskår | |
.EXAMPLE |
{ | |
"$schema": "https://aka.ms/terminal-profiles-schema", | |
"defaultProfile": "{574e775e-4f2a-5b96-ac1e-a2962a402336}", | |
"profiles": | |
[ | |
{ | |
"guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}", | |
"hidden": false, |
param ( | |
[string]$SwaggerUrl, | |
[switch]$Pretty = $false | |
) | |
$paths = Invoke-WebRequest $swaggerUrl | ConvertFrom-Json | Select-Object -ExpandProperty paths | |
$result = @() # result array | |
foreach ($prop in $paths.PSObject.Properties) { | |
$pathName = $prop.Name |
using System; | |
using System.Globalization; | |
namespace Common | |
{ | |
/// <summary> | |
/// A value type representing an Entity Tag (ETag). | |
/// </summary> | |
public struct ETag : IFormattable | |
{ |
FROM microsoft/windowsservercore | |
LABEL Description="Seq Event Server" Vendor="Datalust" Version="4.2.1113" | |
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop';"] | |
RUN Invoke-WebRequest https://getseq.net/Download/Begin?version=4.2.1113 -OutFile c:\seq-installer.msi -UseBasicParsing ; \ | |
Start-Process msiexec.exe -ArgumentList '/i c:\seq-installer.msi /quiet /norestart' -Wait ; \ | |
Remove-Item c:\seq-installer.msi -Force |