xcode Delete current line

Delete a line like eclipse CTRL+D (tested on Xcode 4.5.1) :

First of all, change these rights :

sudo chmod 666 /Applications/Xcode.app/Contents/Frameworks/IDEKit.framework/Resources/IDETextKeyBindingSet.plist

sudo chmod 777 /Applications/Xcode.app/Contents/Frameworks/IDEKit.framework/Resources/

Open /Applications/Xcode.app/Contents/Frameworks/IDEKit.framework/Resources/IDETextKeyBindingSet.plist with Xcode himself and add this new entry :

deleteToBeginningOfLine:, moveToEndOfLine:, deleteToBeginningOfLine:, deleteBackward:, moveDown:, moveToBeginningOfLine:

enter image description here

Restart Xcode and open Xcode > Preferences > KeyBindings. Find your macro and define a shortkey :

enter image description here

原文地址:https://www.cnblogs.com/zsw-1993/p/4879471.html