Skip to content

Instantly share code, notes, and snippets.

@iacchus
Created May 9, 2024 22:03
Show Gist options
  • Save iacchus/db6fa36f9afaaeba8f1fa580e72b6197 to your computer and use it in GitHub Desktop.
Save iacchus/db6fa36f9afaaeba8f1fa580e72b6197 to your computer and use it in GitHub Desktop.
termux keyboard (.termux/termux.properties)
## Configuration with additional popup keys (swipe up from an extra key)
extra-keys = [ \
[ \
{key: ESC, display: ""}, \
{key: ESC, popup: {macro: "CTRL f d", display: "tmux exit"}}, \
{key: CTRL, popup: {macro: "CTRL f BKSP", display: "tmux ←"}}, \
{macro: "ESC :q ENTER", display: ":q", popup: {macro: "ALT g", display: A-g}}, \
{macro: 'y :%s/ CTRL r " //gic LEFT LEFT LEFT LEFT', display: ":%s"}, \
{macro: "cd SPACE TAB", display: "cd", popup: {macro: "ALT g", display: A-g}}, \
{macro: 'CTRL r', display: "<C-r>"}, \
{macro: "CTRL d", display: "<C-d>", popup: {macro: "ALT g", display: A-g}}, \
{macro: "!$", display: "!$", popup: {macro: "ALT g", display: A-g}}, \
{macro: "cd SPACE - ENTER", display: "-", popup: {macro: "ALT g", display: A-g}}, \
{macro: "|", display: "|", popup: {macro: '"sy / CTRL r s ENTER', display: "search selection"}}, \
{key: TAB, popup: {macro: "ALT a", display: A-a}}, \
{key: UP, display: "", popup: {macro: "CTRL u", display: "<C-u>"}}, \
{key: UP, popup: {macro: "CTRL u", display: "<C-u>"}}, \
{key: UP, display: "", popup: {macro: "CTRL u", display: "<C-u>"}}, \
{key: UP, display: "", popup: {macro: "CTRL u", display: "<C-u>"}} \
], \
[ \
{key: KEYBOARD, display: ""}, \
{key: KEYBOARD, popup: {macro: "CTRL d", display: exit}}, \
{key: ALT, popup: {macro: "CTRL f TAB", display: "tmux →"}}, \
{macro: "ESC :w ENTER", display: ":w", popup: {macro: "ALT g", display: A-g}}, \
{macro: 'y :%s/ CTRL r " //gic LEFT LEFT LEFT LEFT', display: ":%s"}, \
{macro: "vim SPACE TAB", display: "vim", popup: {macro: "ALT g", display: A-g}}, \
{macro: "termux-open SPACE TAB", display: "open", popup: {macro: "ALT g", display: A-g}}, \
{macro: "CTRL c", display: "<C-c>", popup: {macro: "ALT g", display: A-g}}, \
{macro: "cd SPACE ~ ENTER", display: "~", popup: {macro: "ALT g", display: A-g}}, \
{macro: "cd SPACE .. ENTER", display: "..", popup: {macro: "ALT g", display: A-g}}, \
{macro: "/", display: "/", popup: {macro: '"sy / CTRL r s ENTER', display: "search selection"}}, \
{key: ENTER}, \
{key: LEFT, popup: {macro: "ESC 0", display: "<ESC>0"}}, \
{key: DOWN, popup: {macro: "CTRL d", display: "<C-d>"}}, \
{key: RIGHT, popup: {macro: "ESC $", display: "<ESC>$"}}, \
{key: RIGHT, display: "", popup: {macro: "ESC $", display: "<ESC>$"}} \
] \
]
@iacchus
Copy link
Author

iacchus commented May 9, 2024

1000061289

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment