5

One of the things which makes TDD nice is the ability to generate code after you have written a test. This is done with the Quick Fix option in Eclipse (Cmd-F1) - or with similar option using Alt-Enter in Jetbrains tools. Most of the usage just involves four options:

  • Create new class
  • Create new method
  • Create new property
  • Create new instance variable

Is there any way to add this ability to Xcode using a plugin, Automator or anything else? I feel that with just four of these in place I could return to using Xcode instead of being stuck in Appcode.

4

2 回答 2

0

不幸的是,我认为这是不可能的。Xcode 的重构工具不如其他一些 IDE 强大(尽管它最近得到了改进)。自从更新到 4.0 后,使用插件或脚本扩展 Xcode 变得更加困难(在此之前至少可以编写脚本)。现在甚至连 Apple Script 支持都没有达到应有的完整程度。

于 2012-07-02T12:38:08.467 回答
0

我遇到了同样的需求,但不幸的是,当前的Xcode 版本对代码重构没有太多支持。我偶然发现的一个工具是Accessorizer

我没有尝试过,但功能和建议看起来很有希望。

希望有帮助:)

于 2012-07-02T12:39:02.213 回答