Skip to content

Commit 55255cc

Browse files
committed
feat: add --dev as alias for --device-name
Some users tried using --dev, so add it as a shorthand alias. https://askubuntu.com/a/1543920/2416571
1 parent 7a4634a commit 55255cc

4 files changed

Lines changed: 19 additions & 12 deletions

File tree

README.md

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,25 @@ numlockw on
3333
Example output:
3434

3535
```
36-
usage: numlockw [-h] [--device-name DEVICE_NAME] [--no-fake-uinput] [--pre-hook PRE_HOOK] [--force-led]
36+
usage: numlockw [-h] [--device-name DEVICE_NAME] [--no-fake-uinput]
37+
[--pre-hook PRE_HOOK] [--force-led]
3738
{on,off,toggle,status,list-devices} ...
3839
39-
numlockw is a program to control the NumLock key, designed for use with Wayland and tty environments.
40+
numlockw is a program to control the NumLock key, designed for use with
41+
Wayland and tty environments.
4042
4143
options:
4244
-h, --help show this help message and exit
43-
--device-name DEVICE_NAME
44-
The name of the input device to use. If not provided, will fake keyboard to enable NumLock, and enable LDE_NUML on all
45-
devices that support it.
45+
--device-name, --dev DEVICE_NAME
46+
The name of the input device or "*" for each one. If
47+
not provided, will fake keyboard to enable NumLock,
48+
and enable LDE_NUML on all devices that support it.
4649
--no-fake-uinput Do not fake uinput device, use real devices
47-
--pre-hook PRE_HOOK A command to run when NumLock is toggled. The command will be run with the status of uinput device name ${{udevice}}.
48-
--force-led Force setting LED_NUML on all devices that support it, not dependent system to set it.
50+
--pre-hook PRE_HOOK A command to run when NumLock is toggled. The command
51+
will be run with the status of uinput device name
52+
${{udevice}}.
53+
--force-led Force setting LED_NUML on all devices that support it,
54+
not dependent system to set it.
4955
5056
actions:
5157
valid actions

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "numlockw"
7-
version = "0.1.4"
7+
version = "0.1.5"
88
authors = [
99
{ name="xz-dev", email="xiangzhedev@gmail.com" },
1010
]

src/numlockw/__main__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,7 @@ def main():
237237
)
238238
parser.add_argument(
239239
"--device-name",
240+
"--dev",
240241
type=str,
241242
default=None,
242243
help='The name of the input device or "*" for each one. If not provided, will fake keyboard to enable NumLock, and enable LDE_NUML on all devices that support it.',

uv.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)