Last active
September 6, 2023 09:06
-
-
Save sebastiancarlos/9dd95a2c3d5957257e51d623972173f7 to your computer and use it in GitHub Desktop.
The less command... now with horizontal scrolling too!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# All my gist code is licensed under the terms of the MIT license. | |
# Video demo: https://www.youtube.com/watch?v=lSOVozD7Iio | |
### Add this to your .bashrc | |
export LESS="--RAW-CONTROL-CHARS --quit-if-one-screen --clear-screen --tilde" | |
# version of less that scrolls | |
alias less="less --chop-long-lines --status-column --rscroll='>'" | |
alias l="less" | |
# version of less that wraps lines | |
alias lesswrap="command less" | |
alias lw="lesswrap" | |
### Add this to your .config/lesskey | |
#command | |
h left-scroll | |
l right-scroll | |
j forw-scroll | |
k back-scroll |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment