import (
    _ "net/http/pprof"
    "net/http"
)| # $ golangci-lint run --config=~/.golangci.yml ./... > lint.txt | |
| version: "2" | |
| linters: | |
| enable: | |
| - asasalint | |
| - asciicheck | |
| - bidichk | |
| - bodyclose | |
| - canonicalheader | 
| #!/usr/bin/env bash | |
| set -Eeuo pipefail | |
| trap cleanup SIGINT SIGTERM ERR EXIT | |
| script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) | |
| usage() { | |
| cat <<EOF | |
| Usage: $(basename "${BASH_SOURCE[0]}") [-h] [-v] [-f] -p param_value arg1 [arg2...] | 
Structured logs are way better than normal logs for a whole bunch of reasons, but they can sometimes be a pain to read in the shell. Take this logline for example:
{"erlang_pid":"#PID<0.1584.0>","level":"error","message":"Got error when retry: :econnrefused, will retry after 1535ms. Have retried 2 times, :infinity times left.","module":"","release":"c2ef629cb357c136f529abec997426d6d58de485","timestamp":"2019-12-17T19:22:11.164Z"}This format is hard for a human to parse. How about this format instead?
error | 2019-12-17T19:21:02.944Z | Got error when retry: :econnrefused, will retry after 1648ms. Have retried 2 times, :infinity times left.
- Settings -> Wifi -> Press and hold your active network
- Select “Modify Network”Select “Show Advanced Options”
- Select “Proxy Settings -> Manual”
- Set your Proxy to: 10.0.3.2 (Genymotion’s special code for the local workstation)
- Set your Port to: 8888
- Press Save
Dockerized Plex with Transmission and Radarr and Sonarr for more easily movies and TV series download.
bin/kafka-topics.sh --zookeeper localhost:2181 --list
bin/kafka-topics.sh --zookeeper localhost:2181 --describe --topic mytopic 
bin/kafka-topics.sh --zookeeper localhost:2181 --alter --topic mytopic --config retention.ms=1000
... wait a minute ...
There are certain files created by particular editors, IDEs, operating systems, etc., that do not belong in a repository. But adding system-specific files to the repo's .gitignore is considered a poor practice. This file should only exclude files and directories that are a part of the package that should not be versioned (such as the node_modules directory) as well as files that are generated (and regenerated) as artifacts of a build process.
All other files should be in your own global gitignore file:
- Create a file called .gitignorein your home directory and add any filepath patterns you want to ignore.
- Tell git where your global gitignore file is.
Note: The specific name and path you choose aren't important as long as you configure git to find it, as shown below. You could substitute
.config/git/ignorefor.gitignorein your home directory, if you prefer.
