Objective-c code Apple style documentation set generator. Gentle Bytes - Crafting useful software

Appledoc reference to input parameter class

Apple documentation has cross reference for input parameters. You can see that NSStringEncoding and NSError are highlighted: enter image description here

But when I use appledoc, there are no cross reference at all: enter image description here

This is my config file:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
    <string>VK iOS SDK</string>

What's wrong?

Source: (StackOverflow)

Appledoc Exception: At least one directory or file name path is required

Cho-Yeung-Lam:gogopiao_v2 apple$ appledoc -o ./doc --project-name gogopiao_v2

as I type the command above, error occur:

At least one directory or file name path is required, use 'appledoc --help'

gogopiao_v2 is the root directory of my project. Hope someone could help me with the problem.

Source: (StackOverflow)


AutoRenewable subscription in app purchases didn't have free trial

As per In App Purchases Guide in apple's developer resources, it clearly says that we can offer free trial option. In App Purchases Guide Table 12-5 from Apple Developer Docs.

But I couldn't able to see it anywhere when I am setting in App purchases in iTunesConnect. Are they still offering that? Where can I find it?

Here is the screen shot of what I see in my iTunesConnect enter image description here

Source: (StackOverflow)

what is the extension of an executable file in an xcode project

I downloaded apple researchkit last month and run its sample. It worked and every thing was fine. This week i tried to run it , i had build failed and the error is that i need to have appledoc:

error: appledoc is required for building ResearchKit's documentation. See http://appledoc.gentlebytes.com

I did some research and i found this page

 [1]: https://github.com/tomaz/appledoc#quick-install

I downloaded the project and built it and i found my

build directory.

But, i didn't know what is the executable file in this directory and how can i add it to the path. Can someone help me ? thanks a lot.

Source: (StackOverflow)

Xcode 5 Documentation Error

I wanted to describe my code like this

/** Loads and parses the XML file*/
+(NSMutableArray *)loadXML:(NSString *)table;

But when I try to use the quick help for loadXML: Xcode crashes with this Error:

ASSERTION FAILURE in /SourceCache/IDEPlugins/IDEPlugins-5064/IDEQuickHelp/Models/IDEQuickHelpContentCreator.m:321
Details:  Error creating XML document from clang-parsed comment block: Error Domain=NSXMLParserErrorDomain Code=73 "Line 1: invalid character in attribute value
Line 1: attributes construct error
Line 1: Couldn't find end of Start Tag Function
" UserInfo=0x7fc78fb98500 {NSLocalizedDescription=Line 1: invalid character in attribute value
Line 1: attributes construct error
Line 1: Couldn't find end of Start Tag Function

Could anyone help me please?

Sorry for my bad english

Source: (StackOverflow)

Getting reference error from appledoc when embedding code in comments

I have some code comments like this:

How to use this method.

@discussion To use it, do something like the following

    id hook = [[STDeallocHook alloc] initWithBlock:^{
        // Do something when 'hook' is dealloced

So the code example is indented with 4 spaces. When I compile the docset with appledoc, it compiles correctly and shows the code as code in the API reference I generate. However back in XCode (Where I have appledoc creating warnings for issues in the doco) I get the warning:

Invalid [[STDeallocHook alloc] reference found hear STDeallocHook.h@16, unknown object: [STDeallocHook !

I think what's happening is that appledoc is looking for markdown links inside the code block.

How can I stop this warning from appearing?

Source: (StackOverflow)

Appledoc can't run in Xcode

So I'm following this tutorial for the appledoc generation (http://objcsharp.wordpress.com/2013/09/24/how-to-generate-beautiful-apple-style-documentation-in-xcode-5/). Nothing happens after the build. Here's the script:

#if [ ${CONFIGURATION} == "Release" ]; then
APPLEDOC_PATH=`which appledoc`
if [ $APPLEDOC_PATH ]; then
--project-name ${PRODUCT_NAME} \
--project-company "Your Name" \
--company-id "com.yourcompany" \
--output ${PRODUCT_NAME}Docs \
--keep-undocumented-objects \
--keep-undocumented-members \
--keep-intermediate-files \
--no-repeat-first-par \
--no-warn-invalid-crossref \
--exit-threshold 2 \

To make sure I install the appledoc correctly, I did the following from the terminal and the doc shows up fine.

appledoc --project-name BabelCPP --project-company "My Name" --company-id com.mycompany --no-create-docset --output ./doc/ ./CaterpillarCount/CaterpillarCount

Am I missing any critical step or setup in Xcode? It seems like the following part didn't execute correctly and it's what terminate this run script:

APPLEDOC_PATH=`which appledoc`
if [ $APPLEDOC_PATH ]; then

Source: (StackOverflow)

Appledoc and custom link description

If I'm doing something stupid, I'm sorry in advance. But I cannot identify my error.

Here is the code (header file):

#import <Foundation/Foundation.h>

 Represents a cover image. It can be a game cover, a trophy image or even a player avatar.

 It has three properties:

 - **NSMutableString uri**: the link that points to the image.
  - E.g.: [A Skyrim trophy image URI] (http://bit.ly/skyrimTrophyImageUri ).

 - **UIImage img**: the actual image. That is, the bitmap.
  - E.g.: 1A9A3826FB6B42C1B08824655A740620BC8E75F9.PNG

 - **ResolutionType resolution**: the image resolution, which comes from an enumeration of this class called __"ResolutionType"__.
  - E.g: SEN_75x41


@interface NHOCCover : NSObject

The result:

enter image description here

I'm following these instructions (at "Custom link descriptions" section).

I also tried:

Maybe Xcode is messing up with the file? On a second related question, do you know if there is a way to block Xcode from automagically create links in its editor? (I mean to change the font color to blue and underline it).

Thanks in advance.

Source: (StackOverflow)

Using appleDoc and ///TODO: comment

I'm working on a project that uses AppleDoc to generate documentation. I want to add some TODO comments in my code eg:

///TODO: Some stuff to be done
  [self doSomeFancyStuff];

The problem is that when I try to generate my project doc I get theses troublesome warnings :

/Users/Me/trunk/MyProject/MyProject/src/MyClass.m:119: MyClass.m@119: Description for parameter 'myParam' missing for -[MyClass myMethod:]

Obviously I could get rid of my TODO comments but I'd like to keep them along with my beautyful doc. Does anybody know how to achieve that ?

Source: (StackOverflow)

Adding documentation on GitHub projects with appledoc

I've noticed some projects on GitHub have documentation pages created with Appledoc and hosted at username.github.com/project/Documentation. For example:

Project: http://pandamonia.github.com/BlocksKit/
Documentation: http://pandamonia.github.com/BlocksKit/Documentation/

How does this work? Is there a way I could do this for my own project?

Source: (StackOverflow)

Not getting appledoc to document NS_ENUM

could someone please explain what I am doing wrong when documenting my typedef NS_ENUM?

This is my syntax:

/** The different menu items
typedef NS_ENUM(NSInteger, kMenuItem) {
    /** The start page */
    kMenuItemStartPage = 0,
    /** The new round item */
    /** The archive item */
    /** The participants item */
    /** The locations item */
    /** The settings */
    /** The contact page */
    /** The count */

 * This is the Menu View Controller.
 * The menu view controller handles the menu the menu and its options. You can access the menu view controller using the `menuContainer` in the `ApplicationDelegate`
@interface MenuTVC : UITableViewController


My run script build phase:

APPLEDOC_PATH=`which appledoc`
if [ $APPLEDOC_PATH ]; then
echo "Generating docs!";
--project-name "${PRODUCT_NAME}" \
--project-company "Sogeti Sverige AB" \
--company-id "se.domain.project" \
--output "Docs" \
--no-install-docset \
--exit-threshold "2" \
--keep-undocumented-objects \
--keep-undocumented-members \
--keep-intermediate-files \
--ignore "Pods" \
--ignore ".m" \
--index-desc "${PROJECT_DIR}/Readme.md" \
echo "AppleDoc not found or installed!"

The result: google chromescreensnapz007

And build result:

From the terminal:

$ which appledoc
$ appledoc --version
appledoc version: 2.2 (build 963)

I just can't seem to figure it out.

Thanks in advance!

Source: (StackOverflow)

Macro or dynamic placeholder in appledoc

In my iOS project, I added screenshot images to the documentation of some classes.
The documentation is generated with appledoc.

Basically, for the class TheViewController, this would look like this:

 * A view controller: awesome and helpful class description.
 * **iPhone Screenshot:**
 * ![](../docs/documentation_data/ViewControllersScreenshotsGallery/screenshots/TheViewController_iPhone.png)
 * **iPad Screenshot:**
 * ![](../docs/documentation_data/ViewControllersScreenshotsGallery/screenshots/TheViewController_iPad.png)

Is there any way to DRY this?
A macro, pre-processing (via preprocess-headerdoc?), dynamic placeholder, script, options fed to appledoc?

Ideally, I would like to just have this:

 * A view controller: awesome and helpful class description.

Bonus point if I don't even have to add the line SCREENSHOTS_FOR_IPAD_AND_IPHONE, and the content is only added if some condition is met (ie, if images are found where expected).

Source: (StackOverflow)

How to indent documentation in appledoc/HeaderDoc (for documentation on blocks that take arguements)

I created a method that has a block as a parameter. The block takes some arguments, so I would like to indent the documentation like Apple does in their methods that have a similar format...

enter image description here

An simple example how this would look in code is:

/** Loads a project from web service.
 @param securityKey The security key.
 @param block The block to execute after the web service returned all data. The block takes five arguments:
     @param data The data.
     @param fields Some fields.
- (void)loadProjectWithSecurityKey:(NSString *)securityKey andCompletion:(void(^)(NSDictionary *data, NSDictionary *fields))completion;

But clearly this will only appear like this in the documentation:

enter image description here

How do I get data and fields to appear indented like Apple's method that takes a block with arguments?

I couldn't find how to do this in Apple's documentation on HeaderDoc

Source: (StackOverflow)

How to check appledoc valid or not in the xcode build phases run script?

i'm working in generating docset for a ios project, but stumped. 

as you known, we can write a sh script for the xcode build phases run script; and i want it run only when the project in release version & the software appledoc already installed, so i write it as follows:

# appledoc Xcode script
APPLEDOC_PATH=`which appledoc`
if [ $APPLEDOC_PATH ]; then
if [ "${CONFIGURATION}" = "Release" ]; then
#   some code here, omit!    #

it seems not work at all! and i know the problem is the command 'which appledoc' went wrong! so the question is:

how to check appledoc valid or not in the xcode build phases run script?
any ideas? please give a hand! thanks!

Source: (StackOverflow)

Xcode 4: custom behavior does not execute my sh script?

I created a custom behavior in Xcode 4 (Xcode > behaviors > edit behaviors > +) in order to launch a shell script (which is configured to be executable). I can invoke the behavior using the menu or my custom shortcut (console shows up as specified), but the script is not executed (no output in the console). The script has been already tested in the terminal and it works fine! and I also created a dummy script with a simple echo and the result is the same... why? How can I debug this?

enter image description here


After solving the problem I realized what I had in mind, if you are interested read my post: Generate beautiful code documentation with a simple shortcut using AppleDoc, Xcode custom behaviors and AppleScript!

Source: (StackOverflow)