Xcode common plug-ins and auto-generated help documents

Source: Internet
Author: User

* One, the Xcode plugin download: *

Vvdocumenter Download: Https://github.com/onevcat/VVDocumenter-Xcode

Xcode Common plugin Download: http://pan.baidu.com/s/1sjLnUFj

* Second, Vvdocumenter installation method: *

The best-of-the-installing is by Alcatraz. Install Alcatraz followed by the instruction, restart your Xcode and press?? 9. You can find Vvdocumenter-xcode in the list and click the icon on left to install.

If you don't like the Alcatraz-A, you can also clone the repo. Then build the Vvdocumenter-xcode target in the Xcode project and the plug-in would automatically be installed in ~/library /application Support/developer/shared/xcode/plug-ins. Relaunch Xcode and type in//above any code for want to write a Do Cument to.

If you want to use other text beside of//to trigger the document insertion, you can find a setting panel by clicking VV Document in the Window menu of Xcode. You can also find some other useful options there, including setting using spaces instead of tab in the Panel or changing The format of generated documentation.

The problem I encountered in the development: Download Xcode plug-in and unzip to ~/library/application Support/developer/shared/xcode/plug-ins, Xcode6.2 under other plug-ins can be used, except vvdocumenter not. The solution is not to be baffled. The Alcatraz,vvdocumenter was later installed to use.

* Three, Appledoc installation method: *

    1. Appledoc Download: Https://github.com/tomaz/appledoc
    2. Appledoc Installation:

The recommended-to-clone GitHub project and compile the tool from Xcode. As cloning GitHub project would create the link to the main repository, it greatly simplifies a future upgrading too. To install, type the following in the Terminal:

clone git://github.com/tomaz/appledoc.git

This creates Appledoc directory. Within you can find Appledoc.xcodeproj Xcode project; Open it and compile Appledoc target-this should work out of the box, however your system must meet minimum system Requir Ements, see below. I recommend copy resulting Appledoc executable from build directory to one of the directories in your path (echo $PATH ) to make it easily accessible.

Optional:appledoc is selfcontained and contains the necessary template files. IF you want to modify these default from Templates subdirectory to one of the expected locations:

~/Library/ApplicationSupport/appledoc~/.appledoc

You can also with install-appledoc.sh script to perform quick installation. Open Terminal and switch to Appledoc directory. Type following command:

sudo sh install-appledoc.sh (if you need templates add '-t default ')
It compiles appledoc and installs its binary to/usr/local/bin and templates (if wanted) to ~/.appledoc by default. You can override this directories with-b and-t options respectively. For example:

sudo sh install-appledoc.-b-t ~/Library/Application\ Support/appledoc

Alternatively with Homebrew:

install appledoc

Homebrew does not install templates by default.

* Four, Appledoc integration xcode:*

    1. Select Top of your project in Project Navigator
    2. Click Add Target
    3. Depending on your project T Ype (IOS or OS X) Choose Aggregate Template
    4. Create new target. I suggest to call it documentation
    5. Click on the build phases and add new build Phase based on Script
    6. Paste The script below into the script window
    7. Adjust variables in section "Start Constants" as required
    8. UNC omment correct ' target ' for your project and comment off another one depending on your project type.
    9. Adjust path to Appledoc binary and Appledoc ' s command-line switches if required
    10. when the generate a docset from your project, build documentation target.
    11. Docset'll is installed into new loction and would become available to Xcode immediately.
    12. to refresh Quick Help (Alt+click) and (Alt+double-click) the need to restart Xcode-to-refresh its index cache.

Below is a working script this can be added to the Xcode Build phases, Run script

#appledoc Xcode Script# Start Constantscompany="ACME"; Companyid="com. ACME "; companyurl="Http://ACME.com"; target="Iphoneos";#target = "MacOSX";Outputpath="~/help";# End Constants/usr/Local/bin/appledoc--project-name"${project_name}"--project-company"${company}"--company-id"${companyid}"--docset-atom-filename"${company}. Atom"--docset-feed-url"${companyurl}/${company}/%docsetatomfilename"--docset- Package-url"${companyurl}/${company}/%docsetpackagefilename"--docset-fallback-url"${companyurl}/${company}"--output"${outputpath}"--publish-docset--docset-platform-family"${target}"--logformat Xcode--keep-intermediate-files--No-repeat-first-par--No-warn-invalid-crossref--Exit-threshold2 "${project_dir}"

Note: target= "Iphoneos", the contents of the quotation marks for your project target name, or build will be wrong. After the build succeeds, you can view the engineering Help documentation for your production at Xcode open, documentation and API Reference. This method is one.

* Five, Appledoc use Method (command line control) *

On the command line tool CD to the path where the project is located, and then type

appledoc   --.--project-name spring3g_v525_test  --project-company"spring3s"--company-id"com.ch".

Or

--no-create-docset  --.--project-name spring3g_v525_test  --project-company"spring3s"--company-id"com.ch".

This generates the Doc folder in the project directory. The Doc folder has a comment page document.

Note: "." and the preceding symbol must add a space otherwise it will be an error. –company-id parameters must also be passed. Adding the –no-create-docset parameter generates a Web page document under the./doc Directory: The Docset-installed.txt file in the/doc directory records the build Help documentation save path.

* Six, Appledoc demo*

Demo Download: Https://github.com/JarryChang/AppledocDemo

* Seven, reference links: *

    1. Https://github.com/onevcat/VVDocumenter-Xcode
    2. Https://github.com/tomaz/appledoc
    3. https://github.com/tomaz/appledoc/blob/master/
    4. Xcodeintegrationscript.markdown

Xcode common plug-ins and auto-generated help documents

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.