Skip to content

Instantly share code, notes, and snippets.

alirobe / reclaimWindows10.ps1
Last active April 14, 2024 11:40
This Windows 10 Setup Script turns off a bunch of unnecessary Windows 10 telemetery, bloatware, & privacy things. Not guaranteed to catch everything. Review and tweak before running. Reboot after running. Scripts for reversing are included and commented. Fork of (different defaults). N.…
### UPDATE: For Win 11, I recommend using this tool in place of this script:
### iwr -useb | iex
alirobe / PostToUrlAsJson.cs
Last active March 25, 2024 14:41
Umbraco Forms Workflow - POST to URL as JSON (with optional Bearer Access Token). Just place this file anywhere in your Umbraco+Forms project, and the dependency injection will pick it up. This will allow you to connect to Microsoft Flow or Zapier or any integration web service, from which you can send to Salesforce/Dynamics/etc.
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Dynamic;
using System.Net;
using System.Text.RegularExpressions;
using Umbraco.Core.Logging;
using Umbraco.Forms.Core;
using Umbraco.Forms.Core.Attributes;
alirobe / setupWindowsServer2016.ps1
Created September 15, 2017 07:37
# Tweaked Win10 Initial Setup Script
# Primary Author: Disassembler <>
# Modified by: alirobe <> based on my personal preferences.
# Version: 2.6.1, 2017-08-02
# Primary Author Source:
# Tweaked Source:
# Tweak difference:
# @alirobe's version is a subset focused on safely disabling telemetry, 'smart' features, and 3rd party bloat ...
alirobe / SecureMediaController.cs
Last active November 23, 2023 02:36
Secure Media Controller for Umbraco v9 Cloud
using Microsoft.AspNetCore.Mvc;
using Umbraco.Cms.Core.Services;
using MimeKit;
using Umbraco.Cms.Core.Models;
using Umbraco.Cms.Core.IO;
namespace UmbracoProject.Controllers
public class SecureMediaController : Controller
alirobe / Convert-DocumentsToMachineReadable.ps1
Created April 12, 2023 12:44
$popplerPath = ".\poppler\bin\pdftotext.exe"
$maxDocs = 1000
$inputPath = ".\source"
$outputPath = ".\dest"
function Convert-FilesToMarkdown {
alirobe / pnp-list-copy.ps1
Last active October 30, 2022 20:54
Copy list contents between lists in SharePoint using PnP
# authored @alirobe for @sopewebtech 2022-06-17
# pnp-list-copy.ps1 :
# this copies list values from source to target
# before using this script, create a new list 'from existing list' in the same site
# then, plug values in below and run. should work for most field types. any issues let me know.
# todo: add batching, add field types
# licensed under GPL V2
$Site = ""
alirobe / gist:590b3e1f0092333fb95e
Created January 23, 2012 01:27
sharepoint form checkbox show/hide
//<script src="/hosted/Style%20Library/jquery-1.7.1.min.js" type="text/javascript"></script><script type="text/javascript">
var cfg= {
'CRM':['CRM Access'],
'SharePoint':['SharePoint Access'],
'GP':['GP Security Role','GP Access Level','GP Company Name'],
'Replace Existing User':['Existing user email address']
for(var i in cfg) {
alirobe / twoLevelDynamicSharePointMenu.css
Created September 5, 2011 05:17
SharePoint 2010 two-level dynamic submenus (jQuery)
.s4-tn li.dynamic {
top:0; left:100%;
.lt-ie9 .s4-tn{
<link rel="import" href="../core-scaffold/core-scaffold.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-menu/core-menu.html">
<link rel="import" href="../core-item/core-item.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-menu/core-submenu.html">
<polymer-element name="my-element">
alirobe / loadfont.js
Created November 4, 2011 03:31
SharePoint 2010 Font Loader
// in IE only, we must ensure that we don't load the font when the page is loaded in a dialog, because this
// breaks the font reference.
// Dialogs work by appending ?isDlg=1 to the end of an existing page and loading it into an iFrame.
function loadFont(fontName) {
var iAmInternetExplorer = navigator.userAgent.indexOf('MSIE') != -1;
var iAmNotInADialog = window.location.href.indexOf('IsDlg') == -1;
// for other browsers, we load this in a conditional comment.
// due to a bug in IE, WOFF fonts can't be loaded twice.
if (iAmInternetExplorer && iAmNotInADialog) {