I want my laptop to run this code at login:
However I have no idea what scripts run at login to get this code to execute, Please can someone tell me how I can get this code to run at login?Code:xmodmap -e 'keycode 12 = 3 sterling'
I want my laptop to run this code at login:
However I have no idea what scripts run at login to get this code to execute, Please can someone tell me how I can get this code to run at login?Code:xmodmap -e 'keycode 12 = 3 sterling'
Put it in a script, then open up /etc/rc.local write the path to the script and save. Reboot and script should run on login.
So:
in gedit write as follows:Code:gedit myscript.sh
saveCode:#! /bin/bash xmodmap -e 'keycode 12 = 3 sterling'
Change permissions
then edit rc.localCode:sudo chmod +x ~/myscript.sh
above the exit 0 line add the following replacing your user name as necessary:Code:sudo gedit /etc/rc.local
RestartCode:/home/yourusername/myscript.sh
No longer participating......
OK, that didn't work. It didn't run that command.
I don't think xmodmap will run properly in rc.local because no DISPLAY variable has been set. You should be able to go to System->Preferences->Session and add the command you want to the startup commands.
Don't try to make something "fast" until you are able to quantify "slow".
It runs right at the end of the boot procedure. Probably very near the time the login screen comes up.
Don't try to make something "fast" until you are able to quantify "slow".
I believe you can still create a script called .xinitrc that runs at login time but, it's probably better to go the System->Preferences->Session method just to keep everything consolidated in one place.
Don't try to make something "fast" until you are able to quantify "slow".
Bookmarks