Create an empty git repo or reinitialize an existing one
$ git init
import * as sprequest from 'sp-request'; | |
let spr = sprequest.create({ | |
username: 'xxx', | |
password: 'xxx', | |
domain: 'xxx' | |
}); | |
spr.post('https://xxx/sites/test/_api/contextinfo', { | |
body: { |
workflow PingUrlParallel { | |
param( | |
[string]$url, | |
[int]$parallelCount = 10, | |
[int]$iterations = 10 | |
) | |
foreach -parallel ($x in 1..$parallelCount) { | |
1..$iterations | %{ |
if(-not (Get-PSSnapin "Microsoft.SharePoint.PowerShell" -ErrorAction SilentlyContinue)){Add-PSSnapin "Microsoft.SharePoint.PowerShell"} | |
# update SharePoint cache token lifetime | |
$SPContentService = [Microsoft.SharePoint.Administration.SPWebService]::ContentService | |
$SPContentService.TokenTimeout = (New-TimeSpan -minutes 5) | |
$SPContentService.Update() | |
# udpate SharePoint claims token lifetime |
cls | |
$error.Clear() | |
################################################################################################## | |
# Load SharePoint Snapin | |
################################################################################################## | |
$snap = Get-PSSnapin | Where-Object {$_.Name -eq 'Microsoft.SharePoint.Powershell'} | |
if ($snap -eq $null) { | |
Write-Host "Loading Powershell Snapin..." -ForegroundColor Yellow | |
Add-PSSnapin Microsoft.SharePoint.Powershell |
< script type = "text/javascript" src = "http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.9.1.min.js" > < /script> < script type = "text/javascript" language = "javascript" > | |
$(document).ready(function() | |
{ | |
$(document.getElementById('Ribbon.ListItem.Manage-LargeMedium-1-2')).addClass('ms-cui-row ms-cui-disabled'); | |
ExecuteOrDelayUntilScriptLoaded(init_disableRibbomButton, "sp.ribbon.js"); | |
}); | |
function init_disableRibbomButton() |
Create an empty git repo or reinitialize an existing one
$ git init
# https://github.com/dansmith | |
# | |
$source = "My Application Name" | |
$wid=[System.Security.Principal.WindowsIdentity]::GetCurrent() | |
$prp=new-object System.Security.Principal.WindowsPrincipal($wid) | |
$adm=[System.Security.Principal.WindowsBuiltInRole]::Administrator | |
$IsAdmin=$prp.IsInRole($adm) |
<# | |
.SYNOPSIS | |
Fetches an access token using the IdentityServer3 token endpoint | |
.DESCRIPTION | |
Modify the parameters so it matches your IdentityServer3 instance. | |
.NOTES | |
File Name : GetToken.ps1 | |
Author : John Korsnes (@johnkors, johnkors) | |
Prerequisite : PowerShell V3 | |
.LINK |
(function() { | |
var nsName = "LS"; // root namespace name | |
var ns = window[nsName]; // root namespace alias | |
var utils = ns.Utils; // utils alias | |
ns.SP = ns.SP || {}; | |
ns.SP.JSOM = { | |
Data: { | |
Sites: {} // cache for Taxonomy terms JSON | |
}, |