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
function glidePicsOffloading() { | |
var range = "G:I"; | |
var publicDriveFolderId = "__google drive folder id___"; | |
var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
// folder where pictures are located | |
var picsfolder = DriveApp.getFolderById(publicDriveFolderId); |
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
[TestMethod] | |
public void TestMethod1() | |
{ | |
var servicebus = new NameSpace(); | |
var subscription1 = new Subscription { Name = "subscription1", Rules = new List<Rule> { new Rule { Filter = "flag='1'" } } }; | |
var subscription2 = new Subscription { Name = "subscription2", Rules = new List<Rule> { new Rule { Filter = "flag='2'" } } }; | |
servicebus.Topics.Add(new Topic { Name = "topic", Subscriptions = new List<Subscription> { subscription1, subscription2 } }); |
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
/* | |
* Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. | |
* See LICENSE in the project root for license information. | |
*/ | |
const request = require('superagent'); | |
/** | |
* Generates a GET request the user endpoint. | |
* @param {string} accessToken The access token to send with the request. |
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
$schema = Get-Content $Env:schema | Out-String | |
$err = ""; | |
Get-ChildItem -Filter "*.json" | Where-Object { ($Env:exclude_json -split ',') -notcontains $_.Name} | ForEach-Object { | |
# first test only json parsing to not mixup error | |
$json = Get-Content $_ | Out-String -ErrorAction:SilentlyContinue | |
if(($json | Test-Json -ErrorAction:SilentlyContinue) -eq $true){ | |
# if json parsing is fine, let's check schema |
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
{ | |
"issue": [ | |
{ | |
"redmine": "Subject", | |
"vsts": "/fields/System.Title" | |
}, | |
{ | |
"redmine": "Author", | |
"vsts": { | |
"property": "/fields/System.CreatedBy", |
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
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
using (var con = new SqlConnection(Properties.Settings.Default.ConnectionString)) | |
{ | |
con.Open(); | |
var serverConnection = new ServerConnection(con); | |
var server = new Server(serverConnection); |
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
var count = 0; | |
var consoleMaxLines = 0; | |
function writeLog(text){ | |
var div = document.getElementById("result"); | |
var datetime = moment.utc(text,'YYYY-MM-DDTHH:mm:ss'); | |
if(datetime.isValid()){ | |
text = text.replace(datetime.format('YYYY-MM-DDTHH:mm:ss'),datetime.local().format('HH:mm:ss')); | |
} |
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
var request = require('request'); | |
var http = require('http'); | |
var express = require('express'); | |
var os = require("os"); | |
var streamoptions = { | |
url: 'https://xxxxxxx.scm.azurewebsites.net/api/logstream', | |
headers: { | |
'Authorization': 'Basic xxxxxxxxxxxxxxxxx' | |
} |
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 class Program | |
{ | |
static JobHost host = null; | |
static void Main(string[] args) | |
{ | |
var cancellationToken = new WebJobsShutdownWatcher().Token; | |
cancellationToken.Register(() => | |
{ | |
ShutdownGraceFully(); | |
host.Stop(); |
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] $AppServiceName = $ENV:AZURE_APPNAME, | |
[string] $CommandLine = $ENV:AZURE_WEBJOBCOMMANDLINE, | |
[string] $Headers = $ENV:AZURE_SCM_HEADERS | |
) | |
Try | |
{ | |
Write-Warning "Killing processes $CommandLine in $AppServiceName" | |
$HeadersHash = ConvertFrom-StringData -StringData $Headers |
NewerOlder