下手な高速化で地獄を見たお話 ~ XCode編 ~

こういうエラーが起きました。

f:id:cflat-inc:20140715144324p:plain

「Could not insert new outlet connection: Could not find any information for the class named」というエラー。

第一手:IDEIndexDisableという犯人

スタックオーバーフローさん等でいろいろ解決方法が載っており、それらを片っ端から実行していったのですが、ダメ。 XCodeをアップデートしてもダメ。

そんな時この記事で一つ見逃していた箇所を発見。 ios6 - Could not insert new outlet connection - Stack Overflow

I recently came across this problem. I soon realized that the cause had been my own doing. I had previously disabled XCode indexing (which used to take forever & eat up my RAM), using the below code in a terminal window:

defaults write com.apple.dt.XCode IDEIndexDisable 1 To revert XCode to its default state, i used the following line in a terminal window:

defaults write com.apple.dt.XCode IDEIndexDisable 0 Voila! All's well again..

ほほう。。。。これは。。。。過去に

terminalを開いて defaults write com.apple.dt.XCode IDEIndexDisable 1 これで、おっけい。(・∀・)

みたいな記事を参考に、インデックス機能をオフにしたことがあるという記憶がヨミガエってきたのでした。 犯人はこれだ!!

よっしゃ、

また、Indexingを戻したかったら defaults write com.apple.dt.XCode IDEIndexDisable 0 こうしたらできましたー バンザイ!(゚∀゚)アヒャヒャ

みたいな記事の言う通りに戻してみよう!!

えいっ!!

とやるもこれが戻らない。(゚∀゚)アヒャヒャ

第二手:Preferencesは弱かった

なんで戻らないんだ? ターミナルからでなく、ライブラリ/Preferences/com.apple.dt.XCode.plistを直接書き換えてやったら? これだと、0に書き換えた直後にまた1に戻る。保存もしているのに。 つまり、別のところにも同じ情報持ってるってことですね。Preferencesより強い何かがいるってことですね。

XCodeのアップデートしても効果なかったのだから、アプリケーションフォルダは犯人から除外してよさそうですね。 探してやると、ライブラリ/Cashces/com.apple.dt.Xcodeというやつと、ライブラリ/Saved Application State/com.apple.dt.Xcode.savedStateというやつがいた。 お前たちか、僕をOS再インストールまで追い込もうとしている可愛い子たちは、よしよし。 お前らを削除してこれで気分爽快、綺麗サッパリ、すっきりもっきりだ。

えいっ!!

とやるもこれが戻らない。(゚∀゚)アヒャヒャ

第三手:ゴミは捨てよう

なぜだ、なぜなんだ、どうしてなんだ。

どうして戻らないんだ、この設定は。

もはや打つ手がないぞ。

と思った最後の起死回生の一手、会心の一撃、それは「ゴミ箱を空にすること」。

ゴミ箱行ってもリンク切れてなかったなんて。。。