diff --git a/bin/UpdateOS b/bin/UpdateOS index 28c00aa..c0fe260 100755 --- a/bin/UpdateOS +++ b/bin/UpdateOS @@ -1,12 +1,13 @@ #!/usr/bin/env bash -update_dnf() { +update-dnf() { echo -e "\e[0;96m->\e[0m \e[0;90msudo dnf update --refresh\e[0m" sudo dnf update --refresh sudo dnf needs-restarting --reboothint + # https://dnf-plugins-core.readthedocs.io/en/latest/needs_restarting.html } -update_apt() { +update-apt() { echo -e "\e[0;96m->\e[0m \e[0;90msudo apt update\e[0m" sudo apt update echo -e "\e[0;96m->\e[0m \e[0;90msudo apt upgrade\e[0m" @@ -17,18 +18,18 @@ update_apt() { echo -e "\e[1;96m$(what-os)\e[0m with \e[1;36m$(what-pm)\e[0m" case "$(what-pm)" in "dnf") - update_dnf + update-dnf ;; "apt") - update_apt + update-apt ;; *) - prnt "this script does not have update command for this release" + echo "this script does not have update command for this release" ;; esac -unset -f update_dnf -unset -f update_apt +unset -f update-dnf +unset -f update-apt diff --git a/bin/refresh-bashrcd b/bin/refresh-bashrcd new file mode 100755 index 0000000..df05e70 --- /dev/null +++ b/bin/refresh-bashrcd @@ -0,0 +1,24 @@ +#!/usr/bin/env bash + +ff() { + if command -v "${1}" &> /dev/null; then + echo "${@} > ${HOME}/.bashrc.d/${1}-completion.bash" + "${@}" > "${HOME}"/.bashrc.d/"${1}"-completion.bash + fi +} + + +ff fzf --bash +ff elastic-package completion bash +ff devenv completion bash + +case "$(uname)" in + "Linux") + ff delta --generate-completion bash + ff helm completion bash + ff k9s completion bash + ff kind completion bash + ff minikube completion bash + ff starship completions bash + ;; +esac diff --git a/config/vscode/settings.json b/config/vscode/settings.json index 4fa73d8..64b75e1 100644 --- a/config/vscode/settings.json +++ b/config/vscode/settings.json @@ -92,6 +92,7 @@ }, "gitlens.codeLens.enabled": false, // + // https://github.com/golang/vscode-go/wiki/settings "[go]": { "editor.tabSize": 2, "editor.insertSpaces": false, @@ -221,6 +222,7 @@ //"editor.selectionBackground": "#bb0d8a8c", "tab.activeBorderTop":"#0078d4", "tab.hoverBorder": "#0078d4", + "editorGutter.deletedBackground":"#37373d", }, "[GitHub Dark Default]": { // https://primer.style/primitives/storybook/?path=/story/color-base-scales--all-scales&globals=theme:dark diff --git a/docker/pgadmin/docker-compose.yml b/docker/pgadmin/docker-compose.yml new file mode 100644 index 0000000..b1cddae --- /dev/null +++ b/docker/pgadmin/docker-compose.yml @@ -0,0 +1,20 @@ +services: + # https://hub.docker.com/r/dpage/pgadmin4/tags + node_exporter: + image: dpage/pgadmin4 + container_name: pgadmin4 + restart: unless-stopped + #pid: host + network_mode: host + # ports: + # - "32400:32400/tcp" + # - "1900:1900/udp" + # - "1901:1901/udp" + # #- "5353:5353/udp" + # - "8324:8324/tcp" + # - "32410:32410/udp" + # - "32412:32412/udp" + # - "32413:32413/udp" + # - "32414:32414/udp" + # - "32469:32469/tcp" + # - "3005:3005" diff --git a/scripts/install-fonts-locally b/scripts/install-fonts-locally index 8a4a67b..7af75c5 100755 --- a/scripts/install-fonts-locally +++ b/scripts/install-fonts-locally @@ -210,17 +210,9 @@ __fnt_sourcecodepro() { __install_ibmplex() { - local FLD - FLD="$(ls -d "${1}"/*/ | head -n 1)" - - mkdir -p "${2}/ibm_plex_mono" - cp -r "${FLD}/IBM-Plex-Mono/fonts/complete/otf" "${2}/ibm_plex_mono" - - mkdir -p "${2}/ibm_plex_sans" - cp -r "${FLD}/IBM-Plex-Sans/fonts/complete/otf" "${2}/ibm_plex_sans" - - mkdir -p "${2}/ibm_plex_serif" - cp -r "${FLD}/IBM-Plex-Serif/fonts/complete/otf" "${2}/ibm_plex_serif" + find "${1}/packages" -type d -path '*/fonts/complete/otf' 2>/dev/null | while read -r dir; do + cp "${dir}"/*.otf "${2}" + done } __fnt_ibmplex() { __installing "IBM Plex" @@ -229,9 +221,10 @@ __fnt_ibmplex() { local URL BODY="$( curl --fail --silent --show-error --location https://api.github.com/repos/IBM/plex/releases/latest )" - REMOTE_VERSION="$( echo $BODY | jq '.tag_name' --raw-output | sed 's/^v//g' )" - URL="$( echo $BODY | jq '.zipball_url' --raw-output )" - __install_font_locally "${URL}" "ibmplex.zip" "ibm_plex" __decomp __install_ibmplex "${REMOTE_VERSION}" + REMOTE_VERSION="$( echo $BODY | jq '.tag_name' --raw-output | sed 's/^v//g' | sed 's/[@\/]/_/g' )" + #URL="$( echo $BODY | jq '.zipball_url' --raw-output )" + URL="https://github.com/IBM/plex/archive/refs/heads/master.zip" + __install_font_locally "${URL}" "ibmplex.zip" "ibmplex" __decomp __install_ibmplex "${REMOTE_VERSION}" }