I present to you, a Toggle Sneak and Sprint mod that is 1.12.2 compatible. The Forge Mod Loader is required for this mod.
This is a complete, final release. I will be updating it for newer versions of MC as they come out.
I would like to add a config in the future, but the mod is 100% functional as-is.
The UI is very minimal, you can see it on the left side of the screen.
G - Toggle Sneak On/Off
V - Toggle Sprint On/Off
These controls can be changed in the Minecraft control window. To toggle sneak/sprint, press the appropriate button briefly, and it will hold it down.
The source code for the mod can be found here: https://github.com/MuddledGuy/ToggleSneak
This is a remake of BlauesZebra's Toggle Sneak, which is outdated and has not been updated in over a year, you can find it here: https://github.com/BlueAnanas/ZebrasToggleSneak