Comments (15)
Hm. Need to see what's going one there, but when I saw it last time, there's was not a lot API we can use related to AppCode settings.
from dyci-main.
Parsing ~/Library/Preferences/appcode30/options/other.xml works:
$ xpath ~/Library/Preferences/appCode30/options/other.xml "/application/component[@name='XcodeSettings']/option[@name='selectedXcode']/@value"
Found 1 nodes:
-- NODE --
value="/Applications/Xcode511.app/Contents/Developer"
I might be able to do a patch though I'm not sure how to integrate with the plugin and all that
from dyci-main.
@grav Nice one.
Don't think that I'll be able to get to it till Saturday.
So I'll write my thoughts about this:
- Update dyci_recompile.py to handle additional parameter for xcode location
- Update AppCode plugin for passing "additional parameter" to dyci_recompile.py
from dyci-main.
Just got my Java on and recreated the simple bash one-liner above in Java for the plugin:
https://gist.github.com/grav/d8f44d1a2ad527e764dc
(XPathFactory, sheesh ...)
from dyci-main.
Alright, I did a pull request with your suggestions, with the big disclaimer that I didn't test it, since I haven't tried compiling the plugin for AppCode yet!
from dyci-main.
Okay, now I found out how to link to the correct jars to get the script to compile. I'm still not sure how to build the plugin jar so that I can test it in AppCode. Can you help me out there?
Edit: just for my own reference, this is how I compile:
javac -cp /Applications/AppCode.app/Contents/lib/*:. Support/AppCode/Dyci/src/com/stanfy/dyci/DyciRecompileAndInjectAction.java
from dyci-main.
Well. The plugin was made long time ago
It was created by InteliJ IDEA
http://confluence.jetbrains.com/display/IDEADEV/PluginDevelopment
Read docs there. The plugin version can be outdated
I think you'll be able to do it :)
I'll look to this one on Saturday - a bit busy here.
Also - just to mention - use fallback, to old logic of searching xcode-select, in case if something will be different in AppCode configuration
from dyci-main.
It's may be even faster by using this example:
http://bjorn.tipling.com/how-to-make-an-intellij-idea-plugin-in-30-minutes
from dyci-main.
Thanks for the pointers, I'll look into it!
from dyci-main.
@grav How it's going? need a help? Will have some time to check this out :) Should I wait for you to finish?
from dyci-main.
@PaulTaykalo Didn't get down to looking at the tutorials yet. I did do a pull request with code that now actually compiles, but it is still untested.
It would be great if you could test out the PR. I won't have the time before next week.
from dyci-main.
Okay, I managed to set everything up and build the plugin in IntelliJ 13.
I had to download and build with JDK 1.6 from https://developer.apple.com/downloads/index.action in order to get AppCode to accept the plugin (since it's running on JRE 1.6).
However, I get a weird exception in AppCode when it starts up (or maybe it's when I do Ctrl+x the first time only, in any case, the reaction comes quite late):
Null child action in group Run () of class class com.intellij.openapi.actionSystem.DefaultActionGroup, id=com.stanfy.dyci.DyciRecompileAndInjectAction
java.lang.Throwable
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:113)
at com.intellij.openapi.actionSystem.DefaultActionGroup.unStub(DefaultActionGroup.java:347)
at com.intellij.openapi.actionSystem.DefaultActionGroup.getChildren(DefaultActionGroup.java:303)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl$5.compute(ActionManagerImpl.java:1261)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl$5.compute(ActionManagerImpl.java:1254)
at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:932)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl.preloadActionGroup(ActionManagerImpl.java:1254)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl.preloadActionGroup(ActionManagerImpl.java:1269)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl.preloadActionGroup(ActionManagerImpl.java:1248)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl.doPreloadActions(ActionManagerImpl.java:1239)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl.access$200(ActionManagerImpl.java:73)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl$4.run(ActionManagerImpl.java:1220)
at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:419)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:695)
at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:149)
I've updated the pull request with the updated .iml and changelog: #63
Maybe I'll look into it again later this week, but ping me if you have any clues :-)
Edit: when I build the plugin, I get a 100 MB big plugin with all the AppCode libs for some reason, so I haven't pushed the updated plugin.
from dyci-main.
Well, 100 MB plugin is quite a lot :)
I'll look into your pull request later today thank you for your effort :)
from dyci-main.
Thank you @grav
Closed with #63 / #64
Wasn't sure how to do it correctly, but it seems, that it worked )
from dyci-main.
Well, we also need to handle 3.1 and later installations
from dyci-main.
Related Issues (20)
- Possible install script bug HOT 2
- dyci failing on Xcode 7.1 HOT 12
- Should use Debug only podfile definition HOT 3
- Notifying all classes about injections HOT 4
- Inject not working HOT 1
- Couldn't load file Error HOT 1
- No recompiler found to handle this file(xxx)
- Symbol not found expected in flat namespace HOT 11
- Xcode 8 support ? HOT 15
- how to use dyci in XCode 8.2.1 HOT 2
- would xcodebuild archive can use it? HOT 1
- There should be way to recompile files without clang proxying (No IDE)
- Separate DYCI to tool-projects
- Test issue for Gitter integration check HOT 1
- DyCI problems with Xcode 6.3.2 HOT 3
- Uninstall dyci HOT 1
- Faking up clang : cp: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang-real: Permission denied HOT 1
- Faking up clang : cp: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang-real: Permission denied HOT 1
- Issue with dyci installation on appcode HOT 1
- Installation / uninstallation completely screws up clang HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dyci-main.