M patches.def.h => patches.def.h +3 -3
@@ 139,9 139,9 @@
*/
#define UNLOCKSCREEN_PATCH 0
-/* This patch adds a command line argument -u that keeps the input locked but do not
- * show the lock screen. The original patch simply combines the unlock screen patch and
- * the DPMS patch. Enable DPMS_PATCH separately if you want DPMS.
+/* This patch adds a -u command line argument that keeps input locked without showing the lock
+ * screen. The original patch simply combines the unlock screen patch and the DPMS patch.
+ * Enable DPMS_PATCH separately if you want DPMS.
* https://tools.suckless.org/slock/patches/visual-unlock-dpms/
*/
#define VISUAL_UNLOCK_PATCH 0
M slock.c => slock.c +9 -5
@@ 637,11 637,15 @@ lockscreen(Display *dpy, struct xrandr *rr, int screen)
static void
usage(void)
{
- #if MESSAGE_PATCH || COLOR_MESSAGE_PATCH
- die("usage: slock [-v] [-f] [-m message] [cmd [arg ...]]\n");
- #else
- die("usage: slock [-v] [cmd [arg ...]]\n");
- #endif // MESSAGE_PATCH | COLOR_MESSAGE_PATCH
+ die("usage: slock [-v] "
+ #if VISUAL_UNLOCK_PATCH
+ "[-u] "
+ #endif
+ #if MESSAGE_PATCH || COLOR_MESSAGE_PATCH
+ "[-f] [-m message] "
+ #endif
+ "[cmd [arg ...]]\n"
+ );
}
int