This file contains hidden or 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
# | |
# ~/.bashrc | |
# | |
[[ $- != *i* ]] && return | |
colors() { | |
local fgc bgc vals seq0 | |
printf "Color escapes are %s\n" '\e[${value};...;${value}m' |
This file contains hidden or 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
#!/bin/sh | |
DESIRED_UTF8_LOCALE='en_US.UTF-8' | |
DESIRED_PYTHON_VERSION='2.7.16 3.4.10 3.5.7 3.6.9 3.7.4' | |
# PYTHON_COLLECTION_VERSION='27' | |
# PYTHON_COLLECTION_VERSION='34' | |
# PYTHON_COLLECTION_VERSION='35' | |
PYTHON_COLLECTION_VERSION='36' |
This file contains hidden or 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
Apache License | |
Version 2.0, January 2004 | |
http://www.apache.org/licenses/ | |
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION | |
1. Definitions. | |
"License" shall mean the terms and conditions for use, reproduction, | |
and distribution as defined by Sections 1 through 9 of this document. |
This file contains hidden or 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
# Color shortcuts | |
RED=$fg[red] | |
YELLOW=$fg[yellow] | |
GREEN=$fg[green] | |
WHITE=$fg[white] | |
BLUE=$fg[blue] | |
RED_BOLD=$fg_bold[red] | |
YELLOW_BOLD=$fg_bold[yellow] | |
GREEN_BOLD=$fg_bold[green] | |
WHITE_BOLD=$fg_bold[white] |
This file contains hidden or 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
set showcmd " Show (partial) command in status line. | |
set showmatch " Show matching brackets. | |
set incsearch " Incremental search | |
set autowrite " Automatically save before commands like :next and :make | |
set hidden " Hide buffers when they are abandoned | |
set nocompatible " be iMproved, required | |
filetype off " required | |
set nu rnu " Show line numbers and relative line numbers in hybrid mode | |
set ignorecase | |
set smartcase " ...except when serach query contains a capital letter |
This file contains hidden or 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
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. | |
# Initialization code that may require console input (password prompts, [y/n] | |
# confirmations, etc.) must go above this block; everything else may go below. | |
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then | |
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" | |
fi | |
# If you come from bash you might have to change your $PATH. | |
# export PATH=$HOME/bin:/usr/local/bin:$PATH |
This file contains hidden or 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
# Generated by Powerlevel10k configuration wizard on 2020-08-01 at 10:07 CEST. | |
# Based on romkatv/powerlevel10k/config/p10k-rainbow.zsh, checksum 38309. | |
# Wizard options: nerdfont-complete + powerline, large icons, rainbow, unicode, | |
# 24h time, angled separators, sharp heads, sharp tails, 2 lines, disconnected, | |
# no frame, sparse, many icons, concise, instant_prompt=verbose. | |
# Type `p10k configure` to generate another config. | |
# | |
# Config for Powerlevel10k with powerline prompt style with colorful background. | |
# Type `p10k configure` to generate your own config based on it. | |
# |
This file contains hidden or 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
# Add an "alert" alias for long running commands. Use like so: | |
# sleep 10; alert | |
function alert { | |
notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e 's/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//')" | |
} | |
function update_all { | |
echo "Updating all system packages, Flatpak packages, Snap packages, pyenv, npm, and nvm" | |
sudo -p "Please enter your password: " whoami 1>/dev/null | |
( sudo snap refresh & sudo flatpak update -y & pyenv update 2>/dev/null & dotnet tool update powershell --global & wait ) && \ | |
NVM_GIT_VERSION="$(curl -s https://api.github.com/repos/nvm-sh/nvm/tags | jq '.[0].name' | tr -d '"' | cut -c2-)" && \ |
This file contains hidden or 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
#!/bin/bash | |
script_name=$(basename $0) | |
script_version='0.1.0' | |
printf "* %s (%s)\n" "${script_name}" "${script_version}" | |
printf "System loadtest script that recursively forks itself\n" | |
printf "For maximum load:\n" | |
printf "\t * Raise maximum number of open files fs.file-max\n" | |
printf "\t * Raise user number of files soft/hard limits in /etc/security/limits.conf\n" | |
printf "**** CTRL + C to stop ****\n" | |
parent_process=${1:-$$} |
This file contains hidden or 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
# Search through the history for the characters before the cursor using the up | |
# and down arrows. | |
"\e[A": history-search-backward | |
"\e[B": history-search-forward | |
# Delete word forwards | |
"\e[3;3~": kill-word |
OlderNewer