This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:PackageLocation="$(build.artifactstagingdirectory)\\" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { diff } from "deep-object-diff"; // Available on NPM, includes its own TypeScript bindings | |
const deepEqualMatcher: jasmine.CustomMatcher = { | |
compare: function(actual: any, expected: any) { | |
let diffObj = diff(expected, actual); | |
let result: jasmine.CustomMatcherResult; | |
if (Object.keys(diffObj).length > 0) { | |
result = { | |
pass: false, | |
message: "Expected the objects to be deep-equal but they were not:\n" + JSON.stringify(diffObj, null, 2) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using Newtonsoft.Json; | |
using Newtonsoft.Json.Linq; | |
namespace Questionaire | |
{ | |
internal class QuestionaireNodeConverter : JsonConverter | |
{ | |
public override void WriteJson(JsonWriter writer, object value, JsonSerializer serializer) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Param( | |
[string]$serverName, | |
[string]$databaseName, | |
[string]$jurisdictionFilesPath, | |
[string]$jurisdictionName | |
) | |
$filter = $jurisdictionName+"_*.psv" | |
Get-ChildItem $jurisdictionFilesPath -Filter $filter | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import * as React from 'react'; | |
import TextField from 'react-md/lib/TextFields'; | |
interface Props { | |
id: string; | |
label: React.ReactNode; | |
clearOnFocus: boolean; | |
step: number; | |
min?: number; | |
max?: number; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void Upsert(ParentEntity parentEntity) { | |
ParentEntity existing = DB.Parents.Find(parentEntity.Id); | |
if (existing == null) { | |
DB.Parents.Add(parentEntity); | |
} else { | |
var newChildKeys = new HashSet<int>(parentEntity.Children.Select(m => m.Id)); | |
var existingChildren = DB.Children.Where(m => m.ParentId == parentEntity.Id).ToArray(); | |
var existingChildrenKeys = new HashSet<int>(existingChildren.Select(m => m.Id)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=PulseAudio system server | |
After=avahi-daemon.service network.target | |
[Service] | |
Type=forking | |
ExecStart=/usr/bin/pulseaudio --realtime --no-cpu-limit --system --disallow-exit --daemon | |
ExecReload=/bin/kill -HUP $MAINPID | |
Restart=always |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Write-Host "Installing MySQL" | |
$mySqlInstaller = DownloadTempFile -Url "https://downloads.mysql.com/archives/get/file/mysql-installer-community-5.7.27.0.msi" -Filename "mysql-installer-community-5.7.27.0.msi" | |
Invoke-Process "msiexec" "/i $mySqlInstaller /qb" | |
Invoke-Process "${env:ProgramFiles(x86)}\MySQL\MySQL Installer for Windows\MySQLInstallerConsole.exe" "community install server;5.7.27;X64:*:servertype=Server;passwd=password -Silent" | |
Write-Host "Installing MySQL Workbench 8.0.16" | |
Invoke-Process "${env:ProgramFiles(x86)}\MySQL\MySQL Installer for Windows\MySQLInstallerConsole.exe" "community install workbench;8.0.16;X64:* -Silent" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static Uri ComposeRequestUri(string baseUri, string pathSuffix=null, IDictionary<string, object> queryParameters=null) | |
{ | |
if (string.IsNullOrEmpty(baseUri)) | |
{ | |
throw new ArgumentException($"{nameof(baseUri)} is required", nameof(baseUri)); | |
} | |
var uri = new Uri(baseUri); | |
if (!string.IsNullOrEmpty(pathSuffix)) |
OlderNewer