Let's have some command-line fun with curl, [jq][1], and the [new GitHub Search API][2].
Today we're looking for:
-- hattip https://github.com/lodestone/hyper-hacks | |
-- hattip https://gist.github.com/ttscoff/cce98a711b5476166792d5e6f1ac5907 | |
-- A global variable for the sub-key Hyper Mode | |
k = hs.hotkey.modal.new({}, 'F18') | |
-- Hyper+key for all the below are setup somewhere | |
-- The handler already exists, usually in Keyboard Maestro | |
-- we just have to get the right keystroke sent |
#!/bin/bash | |
# A script to set up a new mac. Uses bash, homebrew, etc. | |
# Focused for ruby/rails development. Includes many utilities and apps: | |
# - homebrew, rvm, node | |
# - quicklook plugins, terminal fonts | |
# - browsers: chrome, firefox | |
# - dev: iterm2, sublime text, postgres, chrome devtools, etc. | |
# - team: slack, dropbox, google drive, skype, etc |
Let's have some command-line fun with curl, [jq][1], and the [new GitHub Search API][2].
Today we're looking for:
I wanted LEDBlinky-style functionality out of my RetroPie cabinet. But I didn't need RGB control or magical frontend integration or anything like that. I had buttons with simple single-color LEDs.
I've got a simple control panel with six buttons per player. All I wanted was this:
// ReSharper disable CheckNamespace | |
namespace RestSharp.Deserializers | |
// ReSharper restore CheckNamespace | |
{ | |
public class DynamicJsonDeserializer : IDeserializer | |
{ | |
public string RootElement { get; set; } | |
public string Namespace { get; set; } | |
public string DateFormat { get; set; } |
{ | |
"header": { | |
"Variant": "standard", | |
"Generator": "NONE", | |
"Base": "Base", | |
"Date": "2017-11-06", | |
"KLL": "0.5c", | |
"Author": "danlangford (Dan Langford) 2017", | |
"Version": "0.1", | |
"Name": "KType", |
# to execute: | |
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force | |
# Install-BoxstarterPackage -PackageName https://gist.githubusercontent.com/raelyard/6783972a17ba1bc14e83/raw/ -DisableReboots | |
Disable-UAC | |
# Windows Explorer has undesirable defaults - fix for this installation: | |
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFullPathInTitleBar -DisableOpenFileExplorerToQuickAccess -EnableShowFrequentFoldersInQuickAccess | |
# Override Chocolatey default of asking for confirmation on everything |
$destinationDirectory = "C:\LocalNuGetTest\" | |
$webClient = New-Object System.Net.WebClient | |
$webClient.Credentials = New-Object System.Net.NetworkCredential("USERNAME", "PASSWORD") | |
$feed =[xml]$webClient.DownloadString("https://hostednugetfeed.com/custom-feed/nuget/v2/Packages") | |
$records = $feed | select -ExpandProperty feed | select -ExpandProperty entry #| select -ExpandProperty content | |
for ($i=0; $i -lt $records.Length; $i++) { | |
$content = $records[$i] | select -ExpandProperty content | |
$properties = $records[$i] | select -ExpandProperty properties |
Get-ChildItem -Path C:\Packages -Recurse -Filter *.nupkg | Copy-Item -Destination C:\Packages -Force |
# Installs golang on Windows. | |
# | |
# # Run script: | |
# .\install-go.ps1 -version 1.9.3 | |
# | |
# # Download and run script: | |
# $env:GOVERSION = '1.9.3' | |
# iex ((new-object net.webclient).DownloadString('SCRIPT_URL_HERE')) | |
Param( | |
[String]$version, |