Skip to content

Instantly share code, notes, and snippets.

Jonathan Morley jonathanmorley

Block or report user

Report or block jonathanmorley

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
jonathanmorley / post-install.bat
Last active Sep 19, 2019 — forked from anonymous/post-install.bat
Remove system apps from windows
View post-install.bat
@rem *** Disable Some Service ***
sc stop DiagTrack
sc stop diagnosticshub.standardcollector.service
sc stop dmwappushservice
sc stop WMPNetworkSvc
sc stop WSearch
sc config DiagTrack start= disabled
sc config diagnosticshub.standardcollector.service start= disabled
sc config dmwappushservice start= disabled
View kitchen.log
# jmorley at hqjmorley901 in ~/Code/cvent/workup on git:update-chefdk ✖︎ [17:16:49]
→ cat .kitchen/logs/kitchen.log
I, [2016-06-22T17:04:18.221084 #82130] INFO -- Kitchen: -----> Starting Kitchen (v1.10.0)
I, [2016-06-22T17:04:20.919588 #82130] INFO -- Kitchen: -----> Creating <policyfile-windows-7-sp1>...
I, [2016-06-22T17:06:37.578585 #82130] INFO -- Kitchen: -----> Converging <policyfile-windows-7-sp1>...
E, [2016-06-22T17:16:49.142003 #82130] ERROR -- Kitchen: ------Exception-------
E, [2016-06-22T17:16:49.142257 #82130] ERROR -- Kitchen: Class: Kitchen::ActionFailed
E, [2016-06-22T17:16:49.142287 #82130] ERROR -- Kitchen: Message: 1 actions failed.
>>>>>> Failed to complete #converge action: [WinRM::CommandExecutor#open must be called before any run methods are invoked] on policyfile-windows-7-sp1
E, [2016-06-22T17:16:49.142303 #82130] ERROR -- Kitchen: ----------------------
View setup_winrm.ps1
$log = "C:\winrm.log"
$http_port = 5985
$https_port = 5986
$appid = '{afebb9ad-9b97-4a91-9ab5-daf4d59122f6}'
"winrm_setup started" | tee $log
# Does everything required for WinRM over HTTP. It also starts and enables the WinRM service
"Using quickconfig to setup WinRM over HTTP" | tee -Append $log
&winrm quickconfig -quiet
jonathanmorley / PS.rb
Created Apr 7, 2016
Powershell REPL for windows kitchen machines over WinRM
View PS.rb
require 'highline/import'
require 'winrm'
endpoint = 'http://localhost:5985/wsman'
winrm =, :negotiate, user: 'vagrant', pass: 'vagrant')
winrm.create_executor do |executor|
loop do
executor.run_powershell_script(ask "PS ...> ") do |stdout, stderr|
STDOUT.print stdout
STDERR.print stderr

Keybase proof

I hereby claim:

  • I am jonathanmorley on github.
  • I am jonmorley ( on keybase.
  • I have a public key whose fingerprint is 78B5 5AA7 D8DF 2DD1 F113 5BEF 18E1 4BEA D14A 5636

To claim this, I am signing this object:

View Linux


$ uname –a                          # Display linux system information
$ uname –r                          # Display kernel release information (refer uname command in detail)
$ hostname                          # Show system host name
$ hostname -i                       # Display the IP address of the host (all options hostname)
$ uptime                            # Show how long system running + load (learn uptime command)
$ last reboot                       # Show system reboot history (more examples last command)
$ cat /etc/redhat_release           # Show which version of redhat installed 
$ date                              # Show the current date and time (options of date command)

Engineering practices

  • Do you use version control? (if not, the interview should be over =))
  • Do you test your code?
  • How do you make sure that all code is understood by more than one person?
  • Do you do code review? Does all code get reviewed?
  • Do you have an issue tracker?
  • Describe your deployment process -- how do you find bugs in your team's code? What recourse do you have when you find a serious bug in production code?
  • Who is responsible for doing deployment? How often do you deploy?
  • How do you think about code correctness?
  • When something goes wrong, how do you handle it? Do devs get shamed for breaking the build?
jonathanmorley /
Last active Nov 26, 2019 — forked from jpsim/
Best possible answers collected so far for [Regex golf]( === WARNING: SPOILERS ===
You can’t perform that action at this time.