new file: dvorakd.sh

new file:   install.sh
	new file:   readme.md
This commit is contained in:
Serguei Chmod777 2016-04-10 17:23:11 +02:00
commit f3d780b57b
3 changed files with 70 additions and 0 deletions

41
dvorakd.sh Normal file
View File

@ -0,0 +1,41 @@
#!/bin/sh
#
# $OpenBSD: dvorakd,v 1.0 2016/10/04 serguei.chmod77
# be cautious, it's under WTFPL licence !
wsconsctl keyboard.map+=" keycode 54 = apostrophe quotedbl "
wsconsctl keyboard.map+=" keycode 55 = comma less "
wsconsctl keyboard.map+=" keycode 56 = period greater "
wsconsctl keyboard.map+=" keycode 57 = p P "
wsconsctl keyboard.map+=" keycode 58 = y Y "
wsconsctl keyboard.map+=" keycode 59 = f F "
wsconsctl keyboard.map+=" keycode 60 = g G"
wsconsctl keyboard.map+=" keycode 61 = c C "
wsconsctl keyboard.map+=" keycode 62 = r R "
wsconsctl keyboard.map+=" keycode 63 = l L "
wsconsctl keyboard.map+=" keycode 64 = slash question "
wsconsctl keyboard.map+=" keycode 65 = equal plus "
wsconsctl keyboard.map+=" keycode 77 = a A "
wsconsctl keyboard.map+=" keycode 78 = o O "
wsconsctl keyboard.map+=" keycode 79 = e E "
wsconsctl keyboard.map+=" keycode 80 = u U "
wsconsctl keyboard.map+=" keycode 81 = i I "
wsconsctl keyboard.map+=" keycode 82 = d D "
wsconsctl keyboard.map+=" keycode 83 = h H "
wsconsctl keyboard.map+=" keycode 84 = t T "
wsconsctl keyboard.map+=" keycode 85 = n N "
wsconsctl keyboard.map+=" keycode 86 = s S "
wsconsctl keyboard.map+=" keycode 87 = minus underscore "
wsconsctl keyboard.map+=" keycode 100 = semicolon colon "
wsconsctl keyboard.map+=" keycode 101 = q Q "
wsconsctl keyboard.map+=" keycode 102 = j J "
wsconsctl keyboard.map+=" keycode 103 = k K "
wsconsctl keyboard.map+=" keycode 104 = x X "
wsconsctl keyboard.map+=" keycode 105 = b B "
wsconsctl keyboard.map+=" keycode 106 = m M "
wsconsctl keyboard.map+=" keycode 107 = w W "
wsconsctl keyboard.map+=" keycode 108 = v V"
wsconsctl keyboard.map+=" keycode 109 = z Z"
wsconsctl keyboard.map+=" keycode 40 = bracketleft braceleft "
wsconsctl keyboard.map+=" keycode 41 = bracketright braceright "

18
install.sh Normal file
View File

@ -0,0 +1,18 @@
#!/bin/sh
# Let's make US_Dvorak layout default at boot.
# to be executed as root;
file="/etc/rc.local"
cp ./dvorakd.sh /usr/local/bin/
if [ -f "$file" ]
then
echo 'sh /usr/local/bin/dvorakd.sh' >> /etc/rc.local
else
echo '#!/bin/sh' > /etc/rc.local
echo 'sh /usr/local/bin/dvorakd.sh' >> /etc/rc.local
fi
# reboot the machine to let changes happen,
# or just ``$ sh ./dvorakd.sh'' to test it.

11
readme.md Normal file
View File

@ -0,0 +1,11 @@
```
The reason of such a tiny script came from an annoyance reckonning
the lack of Dvorak layout while grepping it to # kbd -l, on my OpenBSD
running on a Sparc64 machine (otherwise, this layout just exists among
plenty others for standard arch)...
So with valuable tips from #gcu squad people, I just avoid the
hardiest way by re-mapping the QWERTY keyboard into US_Dvorak layout,
using wsconsctl.
I hope it could help some oddball *BSD users.
```