+ Added run in octave shortcut

This commit is contained in:
ziro 2021-03-06 08:57:56 +07:00
parent eb693a8e70
commit ba50738426
5 changed files with 12 additions and 5 deletions

View file

@ -1,5 +1,5 @@
#!/usr/bin/env python3
import sys
import os
sys.ps1='\x1b[1;49;34m\n{}\n\x1b[1;49;32m!>\x1b[0m '.format(os.getlogin()) # bright yellow
sys.ps2='\x1b[1;49;34m?>\x1b[0m ' # bright red
# import sys
# import os
# sys.ps1='\x1b[1;49;34m\n{}\n\x1b[1;49;32m!>\x1b[0m '.format(os.getlogin()) # bright yellow
# sys.ps2='\x1b[1;49;34m?>\x1b[0m ' # bright red

View file

@ -33,7 +33,7 @@ endif
autocmd FileType sh map <buffer> <F9> :w<CR>:vs<CR>:ter sh "%"<CR>
autocmd FileType sh imap <buffer> <F9> <esc> :w<CR>:vs<CR>:ter sh "%"<CR>
" c (untested)
" c
autocmd FileType c map <buffer> <F9> :w<CR>:vs<CR>:ter gcc "%" -o %< && ./%< && read<CR>
autocmd FileType c imap <buffer> <F9> <esc> :w<CR>:vs<CR>:ter gcc "%" -o %< && ./%< && read<CR>
@ -43,6 +43,10 @@ autocmd FileType markdown imap <buffer> <F9> <esc> :w<CR>:!pandoc -o "%:r.pdf" -
" Open pdf via zathura if exist
autocmd FileType markdown map <leader>o :!setsid pdfview "%:r.pdf"<CR><CR>
" m (matlab/octave)
autocmd FileType sh map <buffer> <F9> :w<CR>:vs<CR>:ter octave "%"<CR>
autocmd FileType sh imap <buffer> <F9> <esc> :w<CR>:vs<CR>:ter octave "%"<CR>
" ----- Automatically Render PDF
autocmd FileType plaintex command! -nargs=0 Lw w !pdflatex % > /dev/null
autocmd FileType tex command! -nargs=0 Lw w !pdflatex % > /dev/null

View file

@ -77,6 +77,7 @@ augroup END
autocmd BufEnter *.py set ai sw=4 ts=4 sta et fo=croql
autocmd BufEnter *.c set ai sw=4 ts=4 sta et fo=croql
autocmd BufEnter *.md set ai sw=3 ts=3 sta et fo=croql
autocmd Filetype html set ai sw=3 ts=4 sta et fo=croql
" ----- Auto refresh vimrc
augroup myvimrc

View file

@ -16,6 +16,7 @@ xrdb ${XDG_CONFIG_HOME:-$HOME/.config}/Xresources &
unclutter &
dunst &
numlockx &
lxpolkit &
# Custom Resolutions
xrandr --newmode "768x432" 25.75 768 792 864 960 432 435 440 450 -hsync +vsync

View file

@ -4,6 +4,7 @@
PATH="$(du "$HOME/.local/bin/" | cut -f2 | paste -sd ':')${PATH:+:${PATH}}"
# DEFAULT
export QT_QPA_PLATFORMTHEME='qt5ct'
if [[ -n $SSH_CONNECTION ]]; then
export EDITOR='vim'
else