Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assuming tpm is installed #63

Open
wants to merge 39 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
89fde95
persistent folds
iddoeldor Sep 4, 2019
2961c7d
Update tmux.conf
iddoeldor Sep 4, 2019
943627c
Update tmux-keybindings.conf
iddoeldor Sep 4, 2019
5350ea4
Update vimrc.vim
iddoeldor Sep 4, 2019
5ceb401
Update tmux.conf
iddoeldor Oct 28, 2019
756e04a
terminal opacity
iddoeldor Nov 5, 2019
91ca6f0
Delete tmux-keybindings.conf
iddoeldor Nov 5, 2019
70aa6a2
terminal opacity prompt
iddoeldor Nov 5, 2019
ab36c98
Rename deploy to deploy.sh
iddoeldor Nov 6, 2019
c23731b
add fzf
iddoeldor Nov 6, 2019
d88a796
fzf browser history
iddoeldor Nov 6, 2019
e8488fe
man page split view
iddoeldor Nov 8, 2019
b78fb48
Update vimrc.vim
iddoeldor Nov 18, 2019
0ad27ba
Update deploy.sh
iddoeldor Nov 18, 2019
95d1092
Delete copy
iddoeldor Nov 18, 2019
53f26c7
Update tmux.conf
iddoeldor Nov 18, 2019
6ba9e8b
Delete README.md
iddoeldor Nov 18, 2019
6f2e84e
Update deploy.sh
iddoeldor Nov 18, 2019
47a7a5a
Update deploy.sh
iddoeldor Nov 18, 2019
d37c493
add deps
iddoeldor Nov 19, 2019
6b1d881
Update vimrc.vim
iddoeldor Nov 21, 2019
8d8c870
Update vimrc.vim
iddoeldor Nov 21, 2019
3c88e70
add vim with +xterm_clipboard
iddoeldor Nov 21, 2019
e745808
netrw configuration
iddoeldor Dec 17, 2019
b5939ad
vimrc search highlight change
iddoeldor Apr 7, 2020
4ed5c74
add vimdiff colorscheme
iddoeldor May 18, 2020
d5b1e4d
Create bashrc.sh
iddoeldor Jun 22, 2020
8dc8f40
search word under cursor and open QuickFix
iddoeldor Jun 28, 2020
296f824
Create hotkeys.py
iddoeldor Jul 20, 2020
872c1a8
add vim smali syntax
iddoeldor Sep 3, 2020
3b7db0a
add language & wifi to status bar
iddoeldor Nov 1, 2020
6aedaf5
google search & translate shortcuts
iddoeldor Nov 2, 2020
b7351ca
switch proxy, disable terminal pause
iddoeldor Jan 31, 2021
6b9ed2b
Update vimrc.vim
iddoeldor Jan 31, 2021
cd2732f
start windows and panes at 1, not 0
iddoeldor Jan 31, 2021
c4517ee
Create zshrc
iddoeldor Apr 6, 2021
8675bba
Create tmux.conf
iddoeldor Apr 6, 2021
80dfe50
Create vimrc.vim
iddoeldor Apr 6, 2021
a7fcdb7
Create inputrc
iddoeldor Apr 6, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
95 changes: 0 additions & 95 deletions README.md

This file was deleted.

63 changes: 63 additions & 0 deletions bashrc.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
export VISUAL=vim
export EDITOR="$VISUAL"

shopt -s checkwinsize

alias rand_console='tr -cd "[:alnum:]" < /dev/urandom | fold -w`tput cols`'

# fuzzy search in chrome history
c() {
local cols sep google_history open
cols=$(( COLUMNS / 3 ))
sep='{::}'

if [ "$(uname)" = "Darwin" ]; then
google_history="$HOME/Library/Application Support/Google/Chrome/Default/History"
open=open
else
google_history="$HOME/.config/google-chrome/Default/History"
open=xdg-open
fi
cp -f "$google_history" /tmp/h
sqlite3 -separator $sep /tmp/h \
"select substr(title, 1, $cols), url
from urls order by last_visit_time desc" |
awk -F $sep '{printf "%-'$cols's \x1b[36m%s\x1b[m\n", $1, $2}' |
fzf --ansi --multi | sed 's#.*\(https*://\)#\1#' | xargs $open > /dev/null 2> /dev/null
}

man-find() {
f=$(fd . $MANPATH/man${1:-1} -t f -x echo {/.} | fzf) && man $f
}
fman() {
man -k . | fzf --prompt='Man> ' | awk '{print $1}' | xargs -r man
}

# 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

# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize

# Add an "alert" alias for long running commands. Use like so:
# sleep 10; alert
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'

# vim smali syntax
echo au BufRead,BufNewFile *.smali set filetype=smali >> ~/.vim/filetype.vim
&& mkdir ~/.vim/syntax && cd $_ && wget http://codetastrophe.com/smali.vim

alias switch_proxy='sudo systemctl reload tor.service && curl -s -x socks5h://localhost:9050 ifconfig.me && echo'

# Disable Ctrl+S (Pause) and Ctrl+Q (continue) shortcuts, I use Ctrl+S to save inside Vim
stty -ixon

56 changes: 56 additions & 0 deletions deploy → deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,11 @@ check_for_software vim
echo
check_for_software tmux
echo
check_for_software git
echo
check_for_software xclip
# TODO apt install vim-gnome cmake gcc libssl-dev libwebsockets-dev pkg-config
echo

check_default_shell

Expand All @@ -97,5 +102,56 @@ printf "source '$HOME/dotfiles/zsh/zshrc_manager.sh'" > ~/.zshrc
printf "so $HOME/dotfiles/vim/vimrc.vim" > ~/.vimrc
printf "source-file $HOME/dotfiles/tmux/tmux.conf" > ~/.tmux.conf

git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf
~/.fzf/install

###########################################
# TODO add to .bashrc
c() {
local cols sep google_history open
cols=$(( COLUMNS / 3 ))
sep='{::}'

if [ "$(uname)" = "Darwin" ]; then
google_history="$HOME/Library/Application Support/Google/Chrome/Default/History"
open=open
else
google_history="$HOME/.config/google-chrome/Default/History"
open=xdg-open
fi
cp -f "$google_history" /tmp/h
sqlite3 -separator $sep /tmp/h \
"select substr(title, 1, $cols), url
from urls order by last_visit_time desc" |
awk -F $sep '{printf "%-'$cols's \x1b[36m%s\x1b[m\n", $1, $2}' |
fzf --ansi --multi | sed 's#.*\(https*://\)#\1#' | xargs $open > /dev/null 2> /dev/null
}


man-find() {
f=$(fd . $MANPATH/man${1:-1} -t f -x echo {/.} | fzf) && man $f
}
fman() {
man -k . | fzf --prompt='Man> ' | awk '{print $1}' | xargs -r man
}

export PS1="\t \w\[$(tput sgr0)\]\$ "

[ -f ~/.fzf.bash ] && source ~/.fzf.bash

export VISUAL=vim
export EDITOR="$VISUAL"

alias ll='ls -alF'

shopt -s checkwinsize

alias rand_console='tr -cd "[:alnum:]" < /dev/urandom | fold -w`tput cols`'

###########################################


# TODO download mitmproxy, chrome.. JEB & IDA, apktools, docker..

echo
echo "Please log out and log back in for default shell to be initialized."
40 changes: 40 additions & 0 deletions m/inputrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Make tab autocomplete regardless of filename case.
set completion-ignore-case on

# List all matches in case multiple possible completions are possible.
set show-all-if-ambiguous on

# Immediately add a trailing slash when autocompleting symlinks to directories.
set mark-symlinked-directories on

# Use the text that has already been typed as the prefix for searching through
# commands (i.e. more intelligent Up/Down behavior)
#"\e[B": history-search-forward
#"\e[A": history-search-backward

# Do not autocomplete hidden files unless the pattern explicitly begins with a dot
set match-hidden-files off

# Show all autocomplete results at once
set page-completions off

# If there are more than 200 possible completions for a word, ask to show them all
set completion-query-items 200

# Show extra file information when completing, like `ls -F` does
set visible-stats on

# Be more intelligent when autocompleting by also looking at the text after
# the cursor. For example, when the current line is "cd ~/src/mozil", and
# the cursor is on the "z", pressing Tab will not autocomplete it to "cd
# ~/src/mozillail", but to "cd ~/src/mozilla". (This is supported by the
# Readline used by Bash 4.)
set skip-completed-text on

# Allow UTF-8 input and output, instead of showing stuff like $'\0123\0456'
set input-meta on
set output-meta on
set convert-meta off

# Use Alt/Meta + Delete to delete the preceding word
#"\e[3;3~": kill-word
Loading