Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

Through the day I work on both a Mac and Ubuntu.
What's the best option for mapping the Mac keyboard (an external, non-Mac one) to Ubuntu style keys - when using the Mac (OS X).

Basically I want to have:

Control on keyboard to trigger Command ⌘ keystroke on the Mac
Alt on keyboard to trigger Option ⌥ keystroke on the Mac
Windows on keyboard key to trigger Command ⌘ keystroke on the Mac

Aside from whether this is a good idea or not and which one I should pick, I am just posing the question of how to make the Mac, when used with the external keyboard, to be more Ubuntu-like. My biggest interest is in making sure that vi/vim/macvim and tmux, both of which have a large number of keyboard commands, work the same for my fingers.

I initially thought about this posting on Ask Ubuntu but it actually seems more suitable here.

share|improve this question
    
How do you intend to trigger a <kbd>Control ⌃</kbd> keystroke on the Mac? –  CajunLuke Jun 28 '12 at 0:51
    
I don't understand your concern. Other than remapping the control/command/alt/etc (modifiers), what else is different in Ubuntu? I mean, Cmd+S(ave) is going to be Control+S(ave) on Ubuntu… which is the same. Control+Tab (cmd+tab Mac)… etc. Both OS's have similar shortcuts (which you can redefine under Mac anyway). <puzzled> I use vi on a Mac (and vim) and sometimes under Linux and they are exactly the same… –  Martín Marconcini Jun 28 '12 at 0:54
1  
Mac's not handy, I can check in a bit. –  Michael Durrant Jun 28 '12 at 1:00
1  
I'd say that the "biggest" difference between LInux/Windows and Mac is the CMD key being the centerpiece (instead of Control), which you should swap. Option is Alt and Windows Key is Command. But There's no "Mac" key (like Windows Key) on Mac (or "Linux" key under Linux) so by swapping Cmd<->Control you're pretty much there. Instead of CMD+C to copy, you'd press Control-C (like LInux) and the OS will be doing a CMD+C. :) Other than that… I don't see a huge difference. –  Martín Marconcini Jun 28 '12 at 1:01
1  
@ephsmith That sounds good ! –  Michael Durrant Jun 28 '12 at 1:05

1 Answer 1

up vote 3 down vote accepted

Ok, what you want to do is remap your modifiers:

Go to System Preferences and select Modifier Keys:

Preferences

Then swap Cmd and Control.

Modifiers

note: in the shot they are not swapped

For reference, I do this with an external Razer Blackwidow for Windows (I want it to be like my Mac keyboard because I've been using Mac keyboards for 10 years).

share|improve this answer
    
Yes this works well for me. I like the fact that I have the choice and am applying it to my external keyboards only so my colleagues are not freaked out when they use the mac keyboard temporarily ! –  Michael Durrant Jul 9 '12 at 2:10
1  
+1 for the diagrams they are helpful ! –  Michael Durrant Jul 9 '12 at 2:12

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.