How to install phonegap-2.7.0 for ios? - ios

I have downloaded the phonegap-2.7.0 from http://phonegap.com/,but i don't know how to install it,(There is a Makefile,but nothing happened when execute the "make" command in the terminal,i have already quit the xcode),would anyone help me?

http://docs.phonegap.com/en/2.7.0/guide_getting-started_ios_index.md.html
These instructions are pretty clear, even if the directory tree you get after extracting the zip file is not exactly the one they show.
After installing all the requirements:
extract the content of phonegap-2.7.0.zip wherever you want
go to lib/ios/bin and run the 'create' command with the suggested parameters.
open the finder and go to the directory you used as first parameter of the 'create' command
doubleclick the file with extension xcodeproj to open XCode and the project will be automatically created
To open the finder in the right folder you can use the command line:
open ~/workspace/yourProject
or
cd ~/workspace/yourProject
open `pwd`
my 2c

Related

How can I view the logs generated from the xcodebuild output?

I am currently downloading dependencies via Carthage. When it comes to error, I need to see the log details.
xcodebuild output can be found in /var/folders/fj/1kwwbqhx5r3d0dp1g1fgjwbw0000gn/T/carthage-xcodebuild.dCp7BC.log
Would you please help me hot to redirect to the logs using Terminals and Finder ?
You can use open like below. It will open the file with the default app of the extension.
open /var/folders/fj/1kwwbqhx5r3d0dp1g1fgjwbw0000gn/T/carthage-xcodebuild.dCp7BC.log
You can specify desired app with -a. For example below will open the file using TextEdit
open /var/folders/fj/1kwwbqhx5r3d0dp1g1fgjwbw0000gn/T/carthage-xcodebuild.dCp7BC.log -a TextEdit
Or you can just print it in the terminal using cat
cat /var/folders/fj/1kwwbqhx5r3d0dp1g1fgjwbw0000gn/T/carthage-xcodebuild.dCp7BC.log
Or you can just open the container folder in finder. Remember to delete the file name.
open /var/folders/fj/1kwwbqhx5r3d0dp1g1fgjwbw0000gn/T/

Swiftkotlin command line not found for converting Swift to kotlin

I am using Swift kotlin for converting swift code to kotlin which is working on Xcode project but when I am trying to execute from mac terminal it shows SwiftKotlin not found .
Github link: https://github.com/angelolloqui/SwiftKotlin
-bash: swiftkotlin: command not found
Vivek-Mac-mini:~ vivekrawat$
It looks like you need to install the package into
/usr/local/bin/
folder on your Mac, so the terminal can treat it like other command-line commands like cd, open, etc.
From Xcode, run the desired target and copy the generated executables (you can find it under the Products generated folder) in a directory with executable rights for later use. Typically, you could use:
swiftkotlin command line tool: /usr/local/bin/
To do so, you can try the following:
in the left pane of Xcode find the last folder called Products, open it. There should be a file with .app extension.
try to drag the file with .app extension from XCode to your desktop, holding alt key on the keyboard.
open Finder, click Shift+Cmd+G and paste /usr/local/bin/ into the prompt
drag the file from your desktop to that folder
restart the Terminal and try to use the command again

Universal Linking Validator (Branch) issue

So I am trying to use the Universal Linking Validator on Branch's website. I downloaded the script and opened the terminal and entered:
$ bash ulv_script.sh
Then I dragged and drop the project’s .xcodeproj file into the terminal window the result was:
ulv_script.sh: No such file or directory
How am I suppose to get the link I need?
Here are the directions I am following:
https://dev.branch.io/getting-started/universal-linking-validator/guide/
Jonas from Branch here.
The error you are seeing is because your terminal is in a different directory then the script. You can get around this by using the cd command to navigate to the location of the script.
Alternatively, you can enter bash into the terminal, drag and drop the downloaded script into the terminal window, and then drag and drop your .xcodeproj file into the window. Using this method, you should end up with a command that looks like bash /Users/jbauer/Downloads/ulv_script.sh /Users/jbauer/Desktop/BranchStuff/Branch-TestBed-Swift/TestBed-Swift.xcodeproj Note the space between the path to the script, and the path to the Xcode project.
Feel free to ping me if you run into any other issues, and I'd be happy to lend a hand.

"cannot find original pch source file" while running oclint-xcodebuild manually

So I am using Xcode version 6.3.1 and I am trying to run OClint manually using the link here
So when first time I followed the process I was able to generate compile_commands.json successfully using "oclint-xcodebuild" and while running "oclint-json-compilation-database" I was stuck for long so I tried rerunning "oclint-xcodebuild" deleting the compile_commands.json file and now I am not able to.
The commandline shows this error
"cannot find original pch source file for /var/folders/b_/7xppkkm52111c6pxwcm48k2sd8zptt/C/com.apple.DeveloperTools/6.2-6C131e/Xcode/SharedPrecompiledHeaders/AppX_Prefix-epekrudleryecuadzxmiivcciajs/project_Prefix.pch"
I tried cleaning build.. Doing everyrthing but not much help available online. i am not using cocoapods
Ohkk here what i did so I went to the "/var/folders/b_/7xppkkm52111c6pxwcm48k2sd8zptt/C/com.apple.DeveloperTools/6.2-6C131e/Xcode/SharedPrecompiledHeaders/AppX_Prefix-epekrudleryecuadzxmiivcciajs" path or wherever youer path is and delete all the pch files in the folder with certain extentions.
Delete xcodebuild.log and compile_commands.json and now start with generating the log file again with the whole flow.
It worked :)

Installing Phonegap on iOS

Recently I was trying to install Cordova onto my mac so I can compile for the iphone, but I ran into a problem. The option to create a Cordova project wasn't there on xcode. I looked online and saw that I needed to create the project through the terminal. I did this, but nothing was created as far as I can see.
On the terminal, after dragging the bin folder to the terminal I did: ./create /desktop/ios-program/ com.appname appname
Did I do something wrong? Thanks
here a complete guide is given to create phonegap environment in xcode
http://www.adobe.com/devnet/html5/articles/getting-started-with-phonegap-in-xcode-for-ios.html
if it is not enough than go for this
http://www.kendoui.com/blogs/archive/11-12-27/setup_your_phonegap_development_environment_on_mac.aspx
http://docs.phonegap.com/en/2.7.0/guide_getting-started_ios_index.md.html
These instructions are pretty clear, even if the directory tree you get after extracting the zip file is not exactly the one they show.
After installing all the requirements:
1. extract the content of phonegap-2.7.0.zip wherever you want
2. go to lib/ios/bin and run the create command with the suggested parameters.
3. open the finder and go to the directory you used as first parameter
4. doubleclick the file with extension xcodeproj to open XCode and the project will be automatically created
Make sure that you are inside \phonegap-2.7.0\lib\ios\bin before entering ./create command.
Refer the Blog Tutorial

Resources