Discover gists
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Copy ssh keys to user@host to enable password-less ssh logins. | |
ssh-copy-id user@host | |
To generate the keys use the command ssh-keygen | |
2) Start a tunnel from some machine’s port 80 to your local post 2001 | |
ssh -N -L2001:localhost:80 somemachine |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
var timeoutID; | |
function setup() { | |
this.addEventListener("mousemove", resetTimer, false); | |
this.addEventListener("mousedown", resetTimer, false); | |
this.addEventListener("keypress", resetTimer, false); | |
this.addEventListener("DOMMouseScroll", resetTimer, false); | |
this.addEventListener("mousewheel", resetTimer, false); | |
this.addEventListener("touchmove", resetTimer, false); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -Eeuo pipefail | |
oci="$PWD" # TODO parameter/flag (and pass it aruond to other oci tools correctly!) | |
# ~validate $oci is an OCI layout | |
[ -s "$oci/oci-layout" ] | |
jq -se 'length == 1 and .[0].imageLayoutVersion == "1.0.0"' "$oci/oci-layout" > /dev/null | |
# TODO more/better validation? definitely better error handling |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Visual Studio 2022 | |
Enterprise : | |
VHF9H-NXBBB-638P6-6JHCY-88JWH | |
Professional: | |
TD244-P4NB7-YQ6XK-Y8MMM-YWV2J |
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
- Follow standard conventions.
- Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
- Boy scout rule. Leave the campground cleaner than you found it.
- Always find root cause. Always look for the root cause of a problem.
These are flash cards I made from study materials and nothing here is fit for navigational use.
If you find any errors, please let me know in the comments below.
NewerOlder