Skip to content

Instantly share code, notes, and snippets.

Ro Se RobsonAutomator

Block or report user

Report or block RobsonAutomator

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@RobsonAutomator
RobsonAutomator / create-zip-performance-tests.ps1
Created Jul 12, 2019
Performance tests for create a zip archive with PowerShell
View create-zip-performance-tests.ps1
$archivePath = "E:\Test"
$folderToArchive = "E:\Temp\FolderToCompress"
# prepare output folder
mkdir $archivePath -Force
Clear-Host
for( $i = 0; $i -lt 10; $i++ )
{
$measureExtract = Measure-Command {
@RobsonAutomator
RobsonAutomator / expand-zip-performance.ps1
Last active Jul 12, 2019
Performance test for expand ZIP archive
View expand-zip-performance.ps1
$archivePath = "C:\test80MB.zip"
$destinationFolder = "D:\Test"
mkdir $destinationFolder -Force
Clear-Host
for( $i = 0; $i -lt 10; $i++ )
{
$measureExpand = Measure-Command {
@RobsonAutomator
RobsonAutomator / showconfig.cshtml
Last active Mar 14, 2019
Show Sitecore Config - can be useful for CD servers
View showconfig.cshtml
@using Sitecore.Configuration
<!-- Author: Robert Senktas vel RobsonAutomator -->
<!-- Remove this file from server after usage -->
<!-- http://<hostname>/showconfig.cshtml?save=true saves xml to the App_Data folder -->
@{
if (!Context.Request.IsLocal)
{
Response.StatusCode = 404;
return;
}
@RobsonAutomator
RobsonAutomator / copy-items.ps1
Created Dec 6, 2018
Copy items from source to destination
View copy-items.ps1
$destination = 'master:\sitecore\templates\'
$source = 'master:\sitecore\templates\'
$items = Get-ChildItem -Path $source
#use -WhatIf to check
Get-ChildItem -Path $destination | Remove-Item
foreach( $item in $items )
{
Copy-Item $item.ItemPath $destination
@RobsonAutomator
RobsonAutomator / update-license.ps1
Created Feb 15, 2018
Bulk update Sitecore license
View update-license.ps1
#requires -RunAsAdministrator
# Update all licenses
# You can find more about automation with Powershell on http://lets-share.senktas.net
$iisRoot = "C:\inetpub\wwwroot"
$licenseFile = "C:\license.xml"
(Get-ChildItem -Path $iisRoot -Filter 'license.xml' -Recurse).DirectoryName | % { Copy-Item -Path $licenseFile -Destination $_ -Verbose}
@RobsonAutomator
RobsonAutomator / sif-requirement.ps1
Created Jan 18, 2018
Sitecore Install Framework requirements
View sif-requirement.ps1
#requires -RunAsAdministrator
#requires -Version 5.1
#requires -module SitecoreInstallFramework
#requires -module SitecoreInstallExtensions
@RobsonAutomator
RobsonAutomator / Install-Sitecore8.ps1
Last active Jan 14, 2018
Install Sitecore8 and prerequisites with Sitecore Install Framework and Sitecore Install Extensions
View Install-Sitecore8.ps1
#requires -RunAsAdministrator
#requires -Version 5.1
#requires -module SitecoreInstallFramework
#requires -module SitecoreInstallExtensions
#SIF will install SitecoreInstallExtension; we haven't to import module explicit
Import-Module SitecoreInstallFramework
$folderRoot = "C:\Users\Administrator\Downloads"
View EnableCreativeExchangeLive.ps1
#
# Sitecore will be restarted becasue of change configuration file, please refresh browser!
#
$configDisabled = Join-Path -Path $AppPath -ChildPath "App_Config\Include\Feature\z.SPE.Sync.Enabler.Gulp.config.disabled"
$configEnabled = $configDisabled -replace '.disabled',''
if( Test-Path $configDisabled )
{
$response = Show-Confirm -Title "Enable Creative Exchange Live.`r`nSitecore will be restarted because file $configDisabled will be renamed.`r`nWould you like to continue?"
if( $response -eq 'yes')
@RobsonAutomator
RobsonAutomator / DownloadFromSitecore.ps1
Created Nov 27, 2017 — forked from jermdavis/DownloadFromSitecore.ps1
Download files from dev.sitecore.net from the commandline
View DownloadFromSitecore.ps1
param(
[Parameter(Mandatory=$true)]
[string]$url,
[Parameter(Mandatory=$true)]
[string]$target
)
function Fetch-WebsiteCredentials
{
$file = "dev.creds.xml"
@RobsonAutomator
RobsonAutomator / pssolrservice.ps1
Created Nov 13, 2017
Install Solr as Windows Service without dependencies
View pssolrservice.ps1
#
# PSSolrService.ps1
#
<# region Description
###############################################################################
# #
# File name PSService.ps1 #
# #
# Description A sample service in a standalone PowerShell script #
# #
You can’t perform that action at this time.