diff --git a/.config/i3/config.desk b/.config/i3/config.desk index b2dcd10..f13d984 100644 --- a/.config/i3/config.desk +++ b/.config/i3/config.desk @@ -202,3 +202,8 @@ exec --no-startup-id cadence-session-start --start exec --no-startup-id jack-matchmaker -p ~/.config/jack-matchmaker/patterns exec thunderbird + +# Screenshot +# Selection, highlight, jpeg 9/10 quality, 5px selection border, hide cursor +# Save to file +bindsym Print exec ~/.config/i3/scripts/screenshot.sh diff --git a/.config/i3/config.laptop b/.config/i3/config.laptop index f3cc8f5..ee6f15e 100644 --- a/.config/i3/config.laptop +++ b/.config/i3/config.laptop @@ -212,4 +212,9 @@ exec --no-startup-id jack-matchmaker -p ~/.config/jack-matchmaker/patterns exec xrandr --dpi 160 # Mail client -exec thunderbird \ No newline at end of file +exec thunderbird + +# Screenshot +# Selection, highlight, jpeg 9/10 quality, 5px selection border, hide cursor +# Save to file +bindsym Print exec ~/.config/i3/scripts/screenshot.sh \ No newline at end of file diff --git a/.config/i3/scripts/screenshot.sh b/.config/i3/scripts/screenshot.sh new file mode 100755 index 0000000..247d700 --- /dev/null +++ b/.config/i3/scripts/screenshot.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +path="$SCREENSHOT_PATH" +output=`date +${path}/%Y-%m-%d_%H:%M:%S.jpg` +if [ ! -d "${path}" ]; then + mkdir "${path}" +fi + +touch "${output}" +maim -sl --color=0.6,0.4,0.2,0.2 -f jpg -u -m 9 -b 5 > "${output}" \ No newline at end of file diff --git a/.config/sublime-text-3/Packages/User/Preferences.sublime-settings b/.config/sublime-text-3/Packages/User/Preferences.sublime-settings index de453ac..755b160 100644 --- a/.config/sublime-text-3/Packages/User/Preferences.sublime-settings +++ b/.config/sublime-text-3/Packages/User/Preferences.sublime-settings @@ -1,6 +1,6 @@ { "color_scheme": "Packages/Monokai - Spacegray/Monokai - Spacegray.tmTheme", - "font_size": 10, + "font_size": 11, "ignored_packages": [ "Markdown", diff --git a/.zshrc b/.zshrc index 45b0005..281f63b 100644 --- a/.zshrc +++ b/.zshrc @@ -102,9 +102,17 @@ alias cp="cpv" # To use when .cfg contains a bare git repo. # See this https://developer.atlassian.com/blog/2016/02/best-way-to-store-dotfiles-git-bare-repo/ alias config='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME' + +# Mount VPS as FUSE alias ovh='sshfs chosto@51.75.250.228:/home/chosto /mnt/ovh' +# SSH port forwarding for Picasoft LDAP +alias ldap_pica='sudo ssh -L 389:localhost:389 qduchemi@monitoring.picasoft.net -i /home/.ssh/id_rsa' + # Start ssh-agent and retain passphrase for 1 hour # ssh-add is not used for convenience # Instead "AddKeysToAgent yes" option in ~/.ssh/config for "Host *" eval "$(ssh-agent -s -t 3600)" + +# Default path for screenshots +export SCREENSHOT_PATH=~/img/screenshot \ No newline at end of file diff --git a/README.md b/README.md index 1926927..3a6b9d8 100644 --- a/README.md +++ b/README.md @@ -36,6 +36,7 @@ Configuration makes use of these things, just to record but not mandatory : * Fonts : Noto Sans, Noto Emoji, DejaVu Sans, MaterialIcons, Symbola * xdotool, xsel * gnupg +* maim, for screenshot ### What is this, Chosto ? @@ -61,6 +62,7 @@ Please note : on my system XDG_CONFIG_HOME is $HOME/.config. * Clone in bare repository : `git clone --bare https://github.com/Chostakovitch/dotfiles.git $HOME/.cfg`. A bare repository does not have a working tree (basically it is just `.git` content). So we avoid conflicts with another git repository. * Create a working tree outside `.cfg` : `git --git-dir=$HOME/.cfg/ --work-tree=$HOME checkout`. * Adjust `DEFAUT_USER` in `~/.zshrc`. +* Adjust other environment variables, such as `SCREENSHOT_PATH`. * Source `~/.zshrc` and use provided `config` alias to pull. * `config config --local status.showUntrackedFiles no` to ignore untracked files in status (better as it is home dir).