Skip to content

Instantly share code, notes, and snippets.

View DanRioDev's full-sized avatar
🏠
Working from home BRazil

Dan (Danilo) Rio (Ribeiro) DanRioDev

🏠
Working from home BRazil
View GitHub Profile
@romainl
romainl / vanilla-surround.md
Last active March 16, 2025 10:41
Poor man's Surround

Poor man's Surround

The following shows how to replicate some of Surround's features if you don't happen to have it installed.

NOTE: We only dealt with the simplest cases, here, and the convoluted nature of some of these commands shows how well designed and useful that plugin is. And let's not talk about all the corner cases it handles.

Install it, it's worth it.

The list

@DanRioDev
DanRioDev / tgTABLETMODE.sh
Last active November 19, 2024 23:33
In Linux devices running GNOME toggles the keyboard and touchpad on and off for a proper tablet mode.
#!/bin/sh
# toggle tablet mode script
#
# Toggles the keyboard and touchpad on and off for tablet mode on many devices
# PLEASE ENSURE THAT YOU ARE USING GNOME OR RUNNING SOME ONBOARD KEYBOARD APP BEFORE RUNNING THIS SCRIPT.
# This toggler a system variable named TABLET_MODE, OFF and then turns it ON
# Depends on `notify-send` and `xinput`
# if you dont have any: `brew install libnotify xinput`
# Must run using `source ./tgTABLETMODE.sh`
# would appreciate if anyone could turn this in a GNOME Plugin