Standard escape codes are prefixed with Escape
:
- Ctrl-Key:
^[
- Octal:
\033
- Unicode:
\u001b
- Hexadecimal:
\x1B
- Decimal:
27
#! /bin/zsh | |
################################################################################# | |
### User Custom Config for ZSH theme "spaceship" ### | |
################################################################################# | |
#echo "inside user custom spaceship configs" | |
### | |
# utf8 chars |
SPC | |
SPC: find file | |
, switch buffer | |
. browse files | |
: MX | |
; EX | |
< switch buffer | |
` eval | |
u universal arg | |
x pop up scratch |
/* | |
my indicator in lightdm-gtk-greeter.conf | |
indicators = ~host;~power;~spacer;~~Arch Linux;~spacer;~session;~clock | |
*/ | |
@define-color bg rgba(20, 45, 50, 0.9); | |
@define-color bg_darken rgba(20, 45, 50, 0.75); | |
@define-color clear rgba(0, 0, 0, 0); | |
@define-color bg_alt #b13041; |
#!/bin/bash | |
# You can call this script like this: | |
# $./volume.sh up | |
# $./volume.sh down | |
# $./volume.sh mute | |
function get_volume { | |
amixer get Master | grep '%' | head -n 1 | cut -d '[' -f 2 | cut -d '%' -f 1 | |
} |
#!/bin/bash | |
# sixcat: Use sixel graphics to show an image inside a terminal. | |
# sixgif: Use sixel graphics to play an animation inside a terminal. | |
# Version 1.0 | |
# hackerb9, June 2017 | |
# Sixel graphics are supported by terminals such as the DEC VT340 and | |
# emulators, such as 'xterm -ti vt340'. |
THIS GIST WAS MOVED TO TERMSTANDARD/COLORS
REPOSITORY.
PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!
#!/bin/bash | |
DIR="${HOME}/images/screenshots" | |
DATE="$(date +%Y%m%d-%H%M%S)" | |
NAME="${DIR}/screenshot-${DATE}.png" | |
LOG="${DIR}/screenshots.log" | |
# Check if the dir to store the screenshots exists, else create it: | |
if [ ! -d "${DIR}" ]; then mkdir -p "${DIR}"; fi |
Objective: Print the lyrics for the current playing song.
How: We'll create a small bash
script to do the fetching for us (using curl
) and then we'll
display it either in the terminal or in our $EDITOR
First we'll need to get the name of the current song and its artist: