Skip to content

Instantly share code, notes, and snippets.

@koi8
koi8 / # kubernetes-helm - 2018-10-23_11-21-34.txt
Created October 23, 2018 08:34
kubernetes-helm on macOS 10.11.6 - Homebrew build logs
Homebrew build logs for kubernetes-helm on macOS 10.11.6
Build date: 2018-10-23 11:21:34
wget -O bootstrap-salt.sh https://bootstrap.saltstack.com
bash bootstrap-salt.sh -M
update zabbix.users set passwd=md5('mynewpassword') where alias='Admin';
//go to https://jenkins/script and run
item = Jenkins.instance.getItemByFullName("job_name")
item.builds.each() { build ->
build.delete()
}
item.updateNextBuildNumber(1)
@koi8
koi8 / ESC.ahk
Created January 1, 2016 14:22
Ctrl+Y вместо ESC
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
^Y::
Send, {ESCAPE}
Return

Transforming Code into Beautiful, Idiomatic Python

Notes from Raymond Hettinger's talk at pycon US 2013 video, slides.

The code examples and direct quotes are all from Raymond's talk. I've reproduced them here for my own edification and the hopes that others will find them as handy as I have!

Looping over a range of numbers

for i in [0, 1, 2, 3, 4, 5]: