diff --git a/.bashrc b/.bashrc index 4e5da2d..6525bed 100644 --- a/.bashrc +++ b/.bashrc @@ -1,7 +1,3 @@ -# ~/.bashrc: executed by bash(1) for non-login shells. -# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) -# for examples - # If not running interactively, don't do anything case $- in *i*) ;; @@ -9,12 +5,9 @@ case $- in esac # don't put duplicate lines or lines starting with space in the history. -# See bash(1) for more options HISTCONTROL=ignoreboth - # append to the history file, don't overwrite it shopt -s histappend - # for setting history length see HISTSIZE and HISTFILESIZE in bash(1) HISTSIZE=1000 HISTFILESIZE=2000 @@ -47,17 +40,17 @@ esac if [ -n "$force_color_prompt" ]; then if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then - # We have color support; assume it's compliant with Ecma-48 - # (ISO/IEC-6429). (Lack of such support is extremely rare, and such - # a case would tend to support setf rather than setaf.) - color_prompt=yes + color_prompt=yes else - color_prompt= + color_prompt= fi fi if [ "$color_prompt" = yes ]; then PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' + + # Use Starship + eval "$(starship init bash)" else PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' fi @@ -75,30 +68,8 @@ esac # enable color support of ls and also add handy aliases if [ -x /usr/bin/dircolors ]; then test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" - alias ls='ls --color=auto' - #alias dir='dir --color=auto' - #alias vdir='vdir --color=auto' - - #alias grep='grep --color=auto' - #alias fgrep='fgrep --color=auto' - #alias egrep='egrep --color=auto' -fi - -# colored GCC warnings and errors -#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01' - -# some more ls aliases -#alias ll='ls -l' -#alias la='ls -A' -#alias l='ls -CF' - -# Alias definitions. -# You may want to put all your additions into a separate file like -# ~/.bash_aliases, instead of adding them here directly. -# See /usr/share/doc/bash-doc/examples in the bash-doc package. - -if [ -f ~/.bash_aliases ]; then - . ~/.bash_aliases + + [ -s "$HOME/Scripts/shell/alias-color.sh" ] && source "$HOME/Scripts/shell/alias-color.sh" fi # enable programmable completion features (you don't need to enable @@ -112,6 +83,28 @@ if ! shopt -oq posix; then fi fi -#THIS MUST BE AT THE END OF THE FILE FOR SDKMAN TO WORK!!! -export SDKMAN_DIR="/home/totoro/.sdkman" -[[ -s "/home/totoro/.sdkman/bin/sdkman-init.sh" ]] && source "/home/totoro/.sdkman/bin/sdkman-init.sh" +######################################### +# APPLICATIONS CONFIG # +######################################### + +[ -s"$HOME/Scripts/shell/alias.sh" ] && source "$HOME/Scripts/shell/alias.sh" +[ -s"$HOME/Scripts/shell/functions.sh" ] && source "$HOME/Scripts/shell/functions.sh" +[ -s"$HOME/Scripts/shell/env.sh" ] && source "$HOME/Scripts/shell/env.sh" + +# nvm +[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm +[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion + +# sdkman +[ -s "$HOME/.sdkman/bin/sdkman-init.sh" ] && source "$HOME/.sdkman/bin/sdkman-init.sh" + +# fzf +[ -s "$HOME/.fzf.bash" ] && source ~/.fzf.bash + +# autojump +[ -s "/usr/share/autojump/autojump.bash" ] && source /usr/share/autojump/autojump.bash + +## cargo +[ -s "$HOME/.cargo/env" ] && source "$HOME/.cargo/env" + +# zprof diff --git a/.config/Code/User/settings.json b/.config/Code/User/settings.json index d5bdadc..ee5e900 100644 --- a/.config/Code/User/settings.json +++ b/.config/Code/User/settings.json @@ -49,6 +49,7 @@ // windows config "window.menuBarVisibility": "toggle", "window.restoreWindows": "none", + "window.autoDetectColorScheme": true, // keyboard "keyboard.dispatch": "keyCode", // zenmode @@ -119,7 +120,7 @@ // "--enable-config" // ] "clangd.path": "/home/totoro/.config/Code/User/globalStorage/llvm-vs-code-extensions.vscode-clangd/install/15.0.3/clangd_15.0.3/bin/clangd", - // prettier + // prettier "prettier.printWidth": 100, "rewrap.wrappingColumn": 100, // vim extension @@ -156,4 +157,6 @@ }, "git.openRepositoryInParentFolders": "never", "editor.minimap.enabled": false, + "window.zoomLevel": 1, + "workbench.colorTheme": "Default Light Modern", } \ No newline at end of file diff --git a/.config/alacritty/alacritty.yml b/.config/alacritty/alacritty.yml index 9ca6d92..dc05712 100644 --- a/.config/alacritty/alacritty.yml +++ b/.config/alacritty/alacritty.yml @@ -1,5 +1,5 @@ import: - - /home/totoro/.config/alacritty/themes/alacritty_0_12.yaml + - /home/totoro/.config/alacritty/themes/atom_one_light.yaml # Any items in the `env` entry below will be added as # environment variables. Some entries may override variables diff --git a/.config/fontconfig/conf.d/01-emoji.conf b/.config/fontconfig/conf.d/01-emoji.conf new file mode 100644 index 0000000..228dde3 --- /dev/null +++ b/.config/fontconfig/conf.d/01-emoji.conf @@ -0,0 +1,30 @@ + + + + + + sans-serif + + Noto Color Emoji + + + + serif + + Noto Color Emoji + + + + monospace + + Noto Color Emoji + + + + Apple Color Emoji + + Noto Color Emoji + + + + diff --git a/.zshrc b/.zshrc index c061b45..537dc71 100644 --- a/.zshrc +++ b/.zshrc @@ -204,7 +204,6 @@ bindkey -s '^o' '^ulfcd\n' # nvm [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm -[ -s "$NVM_DIR/zsh_completion" ] && \. "$NVM_DIR/zsh_completion" # This loads nvm bash_completion # sdkman [ -s "$HOME/.sdkman/bin/sdkman-init.sh" ] && source "$HOME/.sdkman/bin/sdkman-init.sh" @@ -221,4 +220,4 @@ bindkey -s '^o' '^ulfcd\n' ## cargo [ -s "$HOME/.cargo/env" ] && source "$HOME/.cargo/env" -# zprof[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion +# zprof diff --git a/Scripts/basic/brightness b/Scripts/basic/brightness index 982e20b..6542bd4 100755 --- a/Scripts/basic/brightness +++ b/Scripts/basic/brightness @@ -8,8 +8,11 @@ # read about it on archwiki(backlight) # Author: totoro -CUR_BRI=$(cat /sys/class/backlight/intel_backlight/brightness) -MAX_BRI=$(cat /sys/class/backlight/intel_backlight/max_brightness) +BRIGHTNESS_FILE="/sys/class/backlight/intel_backlight/brightness" +MAX_BRIGHTNESS_FILE="/sys/class/backlight/intel_backlight/max_brightness" + +CUR_BRI=$(cat "$BRIGHTNESS_FILE") +MAX_BRI=$(cat "$MAX_BRIGHTNESS_FILE") # calculating 5 percent of max-brightness ((STEP = MAX_BRI * 5 / 100)) @@ -18,11 +21,11 @@ case $1 in -inc) ((NEW_BRI = CUR_BRI + STEP)) if ((NEW_BRI < MAX_BRI)); then - echo $NEW_BRI | tee /sys/class/backlight/intel_backlight/brightness + echo $NEW_BRI | tee "$BRIGHTNESS_FILE" ((NEW_PER = NEW_BRI * 100 / MAX_BRI)) dunstify -a "Brightness" "Brightness" "Increase \nBrightness: " -h int:value:$NEW_PER -r 100 -i brightness-systray else - echo $MAX_BRI | tee /sys/class/backlight/intel_backlight/brightness + echo $MAX_BRI | tee "$BRIGHTNESS_FILE" dunstify -a "Brightness" "Brightness" "Increase \nBrightness: " -h int:value:100 -r 100 -i brightness-systray fi ;; @@ -31,9 +34,9 @@ case $1 in ((MIN_BRI = MAX_BRI * 10 / 100)) ((NEW_BRI = CUR_BRI - STEP)) if ((NEW_BRI > MIN_BRI)); then - echo $NEW_BRI | tee /sys/class/backlight/intel_backlight/brightness + echo $NEW_BRI | tee "$BRIGHTNESS_FILE" else - echo $MIN_BRI | tee /sys/class/backlight/intel_backlight/brightness + echo $MIN_BRI | tee "$BRIGHTNESS_FILE" fi ((NEW_PER = NEW_BRI * 100 / MAX_BRI)) dunstify -a "Brightness" "Brightness" "Decrease \nBrightness: " -h int:value:$NEW_PER -r 100 -i brightness-systray diff --git a/Scripts/basic/fix-resolution b/Scripts/basic/display-resolution similarity index 100% rename from Scripts/basic/fix-resolution rename to Scripts/basic/display-resolution diff --git a/Scripts/basic/idleshutdown b/Scripts/basic/idle-shutdown similarity index 100% rename from Scripts/basic/idleshutdown rename to Scripts/basic/idle-shutdown diff --git a/Scripts/basic/music b/Scripts/basic/media-keys similarity index 100% rename from Scripts/basic/music rename to Scripts/basic/media-keys index 0039799..d04df98 100755 --- a/Scripts/basic/music +++ b/Scripts/basic/media-keys @@ -1,19 +1,19 @@ #!/bin/bash case $1 in --next) - playerctl next --all-players - ;; -play-pause) playerctl play-pause --all-players # dbus-send --print-reply --dest=org.mpris.MediaPlayer2.vlc /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause ;; --previous) - playerctl previous --all-players - ;; -stop) playerctl stop --all-players ;; +-next) + playerctl next --all-players + ;; +-previous) + playerctl previous --all-players + ;; *) exit 1 ;; diff --git a/Scripts/basic/microphone b/Scripts/basic/microphone index fa0d3e2..d53b99a 100755 --- a/Scripts/basic/microphone +++ b/Scripts/basic/microphone @@ -1,9 +1,7 @@ #!/bin/bash -# Use: Toggle the status of the default active mic source for pulseaudio +# Use: Toggle the status of the default active mic source for *pulseaudio* # Dependencies: pactl, dunstify -# Description: mute, unmute active microphone -# Working: # Author: Shivanshu # Get active audio source index diff --git a/VSCode.md b/VSCode.md new file mode 100644 index 0000000..ec7ef45 --- /dev/null +++ b/VSCode.md @@ -0,0 +1,78 @@ +# Visual Studio Code + +- config + - on linux `~/.config/Code` + - on windows `~/AppData/Roaming/Code/` + +- `User` directory contains the config + +## Extensions List + +- C/C++ (Microsoft) +- Python (Microsoft) + +### tex + +- Latex Workshop + - + +### Shell Scripting + +- ShellCheck + - +- ShellMan + - + +### Formatters + +- Prettier +- shell-format + - + +### Themes UI + +- indent rainbow + - + +### Markdown + +- +- +- +- + +- you can style the headings individually using these + +```json +"editor.tokenColorCustomizations": { +"textMateRules": [ + { + "scope": "heading.1.markdown entity.name.section.markdown, heading.1.markdown punctuation.definition.heading.markdown", + "settings": { + "foreground": "#de6a73", + "fontStyle": "bold" + } + }, + { + "scope": "heading.2.markdown entity.name.section.markdown, heading.2.markdown punctuation.definition.heading.markdown", + "settings": { + "foreground": "#c678dd", + "fontStyle": "bold" + } + }, + { + "scope": "heading.3.markdown entity.name.section.markdown, heading.3.markdown punctuation.definition.heading.markdown", + "settings": { + "foreground": "#98c379", + "fontStyle": "bold" + } + }, + { + "scope": "heading.4.markdown entity.name.section.markdown, heading.4.markdown punctuation.definition.heading.markdown", + "settings": { + "foreground": "#e5c07a", + "fontStyle": "bold" + } + } +] +``` \ No newline at end of file