Skip to content

Instantly share code, notes, and snippets.

// Insert your shop name in here
const shopName = "your-shop-name";
// Call this function from Apps Script (found in Extensions menu in Google Sheets)
function updateSheetWithGraphQL() {
// 1. Get your data (using the previous methods)
const response = getFulfilments();
// 2. Navigate to the specific array in your JSON
// Example path: response.data.repository.artifacts.nodes
@JackUkleja
JackUkleja / license.txt
Last active June 7, 2017 08:30
Windows Network Discovery diagnostic script
MIT License
Copyright (c) 2017 Jack Ukleja
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
@JackUkleja
JackUkleja / delete_old_package_versions.ps1
Last active March 8, 2017 05:21
Deletes old packages from your offline VS2017 installer to save on disk space, i.e. you followed instructions from https://docs.microsoft.com/en-us/visualstudio/install/create-an-offline-installation-of-visual-studio
# cd into your offline installation directory and run this to delete any old package versions
gci -Directory *version* | group -Property { $_.Name.Substring(0, $_.Name.IndexOf("version")) } |
where {$_.Count -gt 1 } | % { $_.Group | sort -Property LastWriteTime | select -First 1 | rmdir -Force -Recurse }
@JackUkleja
JackUkleja / Example.cs
Last active May 20, 2016 07:37
"Reflection" using Roslyn - no file locking and no AppDomains required! :-)
// using Microsoft.CodeAnalysis;
// using Microsoft.CodeAnalysis.CSharp;
var references = new [] { MetadataReference.CreateFromFile("My.dll") };
var compilation = CSharpCompilation.Create("_", null, references);
ITypeSymbol myType = compilation.GetTypeByMetadataName("MyNamespace.MyType");
var props = myType.GetMembers().OfType<IPropertySymbol>();