Skip to content

Instantly share code, notes, and snippets.

@harlow
harlow / golang_job_queue.md
Last active July 12, 2024 03:19
Job queues in Golang
@Faheetah
Faheetah / Jenkinsfile.groovy
Last active June 17, 2024 15:05
Jenkinsfile idiosynchrasies with escaping and quotes
node {
echo 'Results included as an inline comment exactly how they are returned as of Jenkins 2.121, with $BUILD_NUMBER = 1'
echo 'No quotes, pipeline command in single quotes'
sh 'echo $BUILD_NUMBER' // 1
echo 'Double quotes are silently dropped'
sh 'echo "$BUILD_NUMBER"' // 1
echo 'Even escaped with a single backslash they are dropped'
sh 'echo \"$BUILD_NUMBER\"' // 1
echo 'Using two backslashes, the quotes are preserved'
sh 'echo \\"$BUILD_NUMBER\\"' // "1"
@johnramsden
johnramsden / arch-linux-basic-surface.md
Last active January 27, 2023 19:33
Basic arch linux install on surface

Arch Linux Install on the Surface Pro 4

From blog post Arch Linux on The Surface Pro 4. Created for Jordi Higuera

If you do have access to a hub, and you have physical access to the machine, letting you plug a keyboard in, you're probably better off using a fresh install ISO. From the Arch Download page download an up to date ISO.

Partitioning

If you've already gone through the steps of shrinking your SSD to give you some extra room on your SSD, once you've booted in to the ISO run lsblk you should see something like this:

@JM-Mendez
JM-Mendez / selection-command.js
Created May 28, 2019 00:31 — forked from erquhart/selection-command.js
Text selection commands for Cypress.io
/**
* Credits
* @Bkucera: https://github.com/cypress-io/cypress/issues/2839#issuecomment-447012818
* @Phrogz: https://stackoverflow.com/a/10730777/1556245
*
* Usage
* ```
* // Types "foo" and then selects "fo"
* cy.get('input')
* .type('foo')