Sometimes, such as when transcribing FORTRAN code, I find it useful to enter uppercase letters without holding down the Shift key.
However, enabling Caps Lock is a problem in command mode. Here is my (admittedly inelegant) workaround:
function! AllCaps()
inoremap a A
inoremap b B
inoremap c C
inoremap d D
inoremap e E
inoremap f F
inoremap g G
inoremap h H
inoremap i I
inoremap j J
inoremap k K
inoremap l L
inoremap m M
inoremap n N
inoremap o O
inoremap p P
inoremap q Q
inoremap r R
inoremap s S
inoremap t T
inoremap u U
inoremap v V
inoremap w W
inoremap x X
inoremap y Y
inoremap z Z
endfunction
command! AllCaps call AllCaps()
I have an similar command called NoAllCaps
that maps them back to normal. It does the job, but it's not pretty.
Is there a better way?