Discuss Scratch
- Discussion Forums
- » Advanced Topics
- » Using python keyboard module as non-root user
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
Last edited by -EmeraldThunder- (Jan. 9, 2022 15:52:22)
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
Last edited by MagicCrayon9342 (Jan. 9, 2022 16:11:37)
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#6)Rather than telling me what I should an shouldn't do please stay on topic and actually help me with my problem,its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
I'm not kidding, running a python file as sudo is EXTREMELY dangerous(#6)Rather than telling me what I should an shouldn't do please stay on topic and actually help me with my problem,its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
Last edited by MagicCrayon9342 (Jan. 9, 2022 19:49:09)
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#8)Then what do you propose I do?I'm not kidding, running a python file as sudo is EXTREMELY dangerous(#6)Rather than telling me what I should an shouldn't do please stay on topic and actually help me with my problem,its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
Well first question towards the dev of that keyboard, why must it be ran as root.(#8)Then what do you propose I do?I'm not kidding, running a python file as sudo is EXTREMELY dangerous(#6)Rather than telling me what I should an shouldn't do please stay on topic and actually help me with my problem,its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#10)It reads raw device files in areas that require you to be the root user to avoid dependencies.Well first question towards the dev of that keyboard, why must it be ran as root.(#8)Then what do you propose I do?I'm not kidding, running a python file as sudo is EXTREMELY dangerous(#6)Rather than telling me what I should an shouldn't do please stay on topic and actually help me with my problem,its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
what such files?(#10)It reads raw device files in areas that require you to be the root user to avoid dependencies.Well first question towards the dev of that keyboard, why must it be ran as root.(#8)Then what do you propose I do?I'm not kidding, running a python file as sudo is EXTREMELY dangerous(#6)Rather than telling me what I should an shouldn't do please stay on topic and actually help me with my problem,its never going to be like Windows, now stop trying to run a python module as sudo its unsafe.(#4)Compose key isn't the sort of thing I want, it's too slow and ugly.shortcuts for accent letters already exist. also don't use a python one lmao. install gnome tweaks and look for compose key.(#2)20.04I'm using Ubuntu 20 and I need to run a .bash file at startup that uses the sudo command.what exactly is this module
However, I can't use the sudo command in a bash file as it requires password input.
Is there any way to use the python keyboard module without needing to be a root user?
and also, 20.04 LTS or 20.10
The module allows you to manipuate the keyboard, I'm using it to add shortcuts for accented letters.
I can do this fine on windows but when I switch over to linux (I dual boot) it's a little bit harder to achieve,
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#12)/dev/input/inputIt reads raw device files in areas that require you to be the root user to avoid dependencies.what such files?
- MagicCrayon9342
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
that sounds like keylogger work lol(#12)/dev/input/inputIt reads raw device files in areas that require you to be the root user to avoid dependencies.what such files?
- god286
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
Stop asking questions MagicCrayon9342 I think we have enough, you're getting quite offtopic
why do you do this all the time?
Here's a StackOverflow answer. You actually can't use the module without root. But apparently there's another module that can do something similar without root. https://stackoverflow.com/a/65862873/

why do you do this all the time?Here's a StackOverflow answer. You actually can't use the module without root. But apparently there's another module that can do something similar without root. https://stackoverflow.com/a/65862873/

- imfh
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
Would setting up the entire bash script to run as root each start solve your problem? If you are just calling sudo python …, then running the entire script as root sounds like a good option.
- -EmeraldThunder-
-
Scratcher
1000+ posts
Using python keyboard module as non-root user
(#15)Is there a function similar to keyboard.add_abbreviation in the PyInput Module.
Stop asking questions MagicCrayon9342 I think we have enough, you're getting quite offtopicwhy do you do this all the time?
Here's a StackOverflow answer. You actually can't use the module without root. But apparently there's another module that can do something similar without root. https://stackoverflow.com/a/65862873/
- Discussion Forums
- » Advanced Topics
-
» Using python keyboard module as non-root user