Skip to content

Instantly share code, notes, and snippets.

@arkag
arkag / Bootstrap.ps1
Last active July 13, 2018 23:01
Install some basic applications and configurations for all machines.
[CmdletBinding(DefaultParameterSetName = 'Set1')]
Param(
[Parameter(Mandatory, ParameterSetName = 'Set1')]
# Currently doesn't support 365 silent installers
[ValidateSet('2016OL'<#,'365IM','365MS'#>)]
[String]$Office,
[Parameter(Mandatory, ParameterSetName = 'Set2')]
[Switch]$NoOffice,
[Parameter(Mandatory)]
[String]$Name,
@arkag
arkag / TypeSpectre.ps1
Last active July 12, 2018 16:41
Simulate typing, backspace, etc...
function Write-HostSimType ($output){
$array = $output.ToCharArray()
foreach ($l in $array){
$delay = 30
if (@(",",".","?","!",":",";") -Contains $l){
$delay = 300
} elseif ($l -Match "`b" ){
$l = "`b `b"
}
Write-Host -NoNewLine $l
qmk_firmware-0.5.214 → make mechmini/v2:2u_space_ortho
Making mechmini/v2 with keymap 2u_space_ortho
avr-gcc (GCC) 7.2.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Size before:
text data bss dec hex filename
smartctl 5.42 2011-10-20 r3458 [x86_64-linux-3.3.4-5.fc17.x86_64] (local build)
Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net
=== START OF INFORMATION SECTION ===
Device Model: INTEL SSDSC2BP240G4
Serial Number: BTJR5124057K240AGN
LU WWN Device Id: 5 5cd2e4 04b7b7a4b
Firmware Version: L2010420
User Capacity: 240,057,409,536 bytes [240 GB]
Sector Size: 512 bytes logical/physical
@arkag
arkag / keybase.md
Created November 9, 2017 03:11
keybase.md

Keybase proof

I hereby claim:

  • I am arkag on github.
  • I am arkag (https://keybase.io/arkag) on keybase.
  • I have a public key ASDYKnB7IZGL2TzMJw2rqqafPq6oSFm81ZYpZJ6ltcy3vwo

To claim this, I am signing this object:

➜ GIT_CURL_VERBOSE=1 git clone https://phabricator.domain.com/diffusion/24/repository.git
Cloning into 'repository'...
* Couldn't find host phabricator.domain.com in the .netrc file; using defaults
* Trying 10.7.0.4...
* Connected to phabricator.domain.com (10.7.0.4) port 443 (#0)
* found 173 certificates in /etc/ssl/certs/ca-certificates.crt
* found 697 certificates in /etc/ssl/certs
* ALPN, offering http/1.1
* SSL connection using TLS1.2 / ECDHE_RSA_AES_128_GCM_SHA256
* server certificate verification OK
➜ sudo nixos-rebuild switch ~
[sudo] password for arkag:
error: anonymous function at /etc/nixos/premium-xcursor-theme.nix:1:1 called with unexpected argument ‘config’, at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:168:8
(use ‘--show-trace’ to show detailed location information)
building Nix...
error: anonymous function at /etc/nixos/premium-xcursor-theme.nix:1:1 called with unexpected argument ‘config’, at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:168:8
(use ‘--show-trace’ to show detailed location information)
building the system configuration...
error: anonymous function at /etc/nixos/premium-xcursor-theme.nix:1:1 called with unexpected argument ‘config’, at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:168:8
(use ‘--show-trace’ to show detailed location
mpw() {
_copy() {
xclip -selection clip
echo >&2 "Copied!"
}
# Empty the clipboard
:| _copy 2>/dev/null
# Start Master Password and copy the output.
paths = [ "$HOME/bin", "/usr/local/bin", "/usr/lib/python2.7/dist-packages", "/usr/lib/python3/dist-packages"]
for i in paths:
$PATH.append(i)
//
lockPref("plugin.state.flash",1);
lockPref("plugin.default_plugin_disabled", true);
lockPref("signon.rememberSignons", false);
defaultPref("browser.startup.homepage", "https://google.com")