Important rules
- explain why
- explain why
- explain why
- help with code review
Important formatting rules
- start with summary line (max 70 characters)
- add more description after empty line
# "cd with history" | |
# | |
# Bash has a nice feature called "directory stack" - sort of "location history": | |
# https://www.gnu.org/software/bash/manual/html_node/The-Directory-Stack.html | |
# However, I find the built-in commands not really convenient. This makes the | |
# directory stack available as a sort of extension to `cd` interface. | |
function _cd { | |
# typing just `_cd` will take you $HOME ;) | |
if [ "$1" == "" ]; then |
Setup | |
----- | |
Vagrantfile | |
``` | |
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
(1..2).each do |i| |
Important rules
Important formatting rules
# GIT heart FZF | |
# ------------- | |
is_in_git_repo() { | |
git rev-parse HEAD > /dev/null 2>&1 | |
} | |
fzf-down() { | |
fzf --height 50% "$@" --border | |
} |
# Synchronize history between bash sessions | |
# | |
# Make history from other terminals available to the current one. However, | |
# don't mix all histories together - make sure that *all* commands from the | |
# current session are on top of its history, so that pressing up arrow will | |
# give you most recent command from this session, not from any session. | |
# | |
# Since history is saved on each prompt, this additionally protects it from | |
# terminal crashes. |
# enable keeping history timestamps and set display format to ISO-8601 | |
export HISTTIMEFORMAT="%F %T " | |
# ignore duplicates and commands starting with space | |
HISTCONTROL=ignoreboth | |
# ignore specific commands (full-length match) | |
HISTIGNORE=”?:cd:ls:ll:bg:fg:vim:git status” | |
# disable terminal flow control key binding, so that ^S will search history forward | |
stty -ixon |
# Use with Vagrantfile liks this: | |
# | |
# # -*- mode: ruby -*- | |
# # vi: set ft=ruby : | |
# | |
# Vagrant.configure("2") do |config| | |
# config.vm.box = "ubuntu/xenial64" | |
# config.vm.provision "ansible" do |ans| | |
# ans.playbook = "ansible-systemd-test.yml" | |
# end |
This tutorial will walk you through typical GPG workflow: generating, signing, trusting, renewing and backing up keys. Instead of long explanations it just shows what happens in practice on test data.
Important: older GPG versions behave significantly different and use
different formats for storing data. This tutorial was tested with GPG
2.2.4; you can check your version using gpg --version
.