diff options
author | Justin R. Miller <incanus@users.noreply.github.com> | 2015-05-04 16:42:26 -0700 |
---|---|---|
committer | Justin R. Miller <incanus@users.noreply.github.com> | 2015-05-04 16:42:26 -0700 |
commit | a2e481eb740c15503f9e21d4fcf193b97a9dc03c (patch) | |
tree | e8f95c8d06a207d3b7ffb54aa548a4f0956ee34c | |
parent | b952f7e64b3ee3c72f492ee7f5f24d3ab28e8683 (diff) | |
parent | 150c695177298e32efcd7b7be206e0ce64d74f80 (diff) | |
download | qtlocation-mapboxgl-a2e481eb740c15503f9e21d4fcf193b97a9dc03c.tar.gz |
Merge pull request #1415 from mapbox/1413-install-ios-docs
refs #1413: provide iOS docs with binary download
-rw-r--r-- | README.md | 4 | ||||
-rw-r--r-- | include/mbgl/ios/MGLMapView.h | 10 | ||||
-rwxr-xr-x | ios/docs/install_docs.sh | 8 | ||||
-rwxr-xr-x | scripts/ios/install.sh | 3 | ||||
-rwxr-xr-x | scripts/ios/package.sh | 20 |
5 files changed, 37 insertions, 8 deletions
@@ -48,8 +48,8 @@ Target OS X: 10.9+ If you merely want to install the library for iOS and try it out as an Objective-C consumer: -0. Use [Homebrew](http://brew.sh/) to install Boost headers: `brew install boost`. -1. Run `make ipackage`. The packaging script will produce the statically-linked `libMapboxGL.a`, `MapboxGL.bundle` for resources, and a `Headers` folder. +0. Use [Homebrew](http://brew.sh/) to install Boost headers and [appledoc](http://gentlebytes.com/appledoc/): `brew install boost appledoc`. +1. Run `make ipackage`. The packaging script will produce the statically-linked `libMapboxGL.a`, `MapboxGL.bundle` for resources, a `Headers` folder, and a `Docs` folder with HTML API documentation. 2. Copy the contents of `build/ios/pkg/static` into your project. It should happen automatically, but ensure that: - `Headers` is in your *Header Search Paths* (`HEADER_SEARCH_PATHS`) build setting. - `MapboxGL.bundle` is in your target's *Copy Bundle Resources* build phase. diff --git a/include/mbgl/ios/MGLMapView.h b/include/mbgl/ios/MGLMapView.h index 88d75088bf..7c757ba93c 100644 --- a/include/mbgl/ios/MGLMapView.h +++ b/include/mbgl/ios/MGLMapView.h @@ -179,13 +179,17 @@ IB_DESIGNABLE /** Currently active style classes, represented as an array of string identifiers. */ @property (nonatomic) NSArray *styleClasses; -/** Returns a Boolean value indicating whether the style class with the given identifier is currently active. */ +/** Returns a Boolean value indicating whether the style class with the given identifier is currently active. + @param styleClass The style class to query for. + @return Whether the style class is currently active. */ - (BOOL)hasStyleClass:(NSString *)styleClass; -/** Activates the style class with the given identifier. */ +/** Activates the style class with the given identifier. + @param styleClass The style class to activate. */ - (void)addStyleClass:(NSString *)styleClass; -/** Deactivates the style class with the given identifier. */ +/** Deactivates the style class with the given identifier. + @param styleClass The style class to deactivate. */ - (void)removeStyleClass:(NSString *)styleClass; #pragma mark - Annotating the Map diff --git a/ios/docs/install_docs.sh b/ios/docs/install_docs.sh index cd6fcdda73..c74c6bcd2e 100755 --- a/ios/docs/install_docs.sh +++ b/ios/docs/install_docs.sh @@ -5,13 +5,15 @@ if [ -z `which appledoc` ]; then exit 1 fi -VERSION=$( git tag | grep ^[0-9] | sort -r | sed -n '1p' ) +OUTPUT="/tmp/`uuidgen`" + +VERSION=$( git tag -l ios\* --sort -v:refname | sed -n '1p' | sed 's/ios-v//' ) echo "Creating new docs for $VERSION..." echo appledoc \ - --output /tmp/`uuidgen` \ - --project-name "Mapbox GL $VERSION" \ + --output $OUTPUT \ + --project-name "Mapbox GL for iOS $VERSION" \ --project-company Mapbox \ --create-docset \ --company-id com.mapbox \ diff --git a/scripts/ios/install.sh b/scripts/ios/install.sh index 9e649e450e..8da90ec3bb 100755 --- a/scripts/ios/install.sh +++ b/scripts/ios/install.sh @@ -12,4 +12,7 @@ export PATH="`pwd`/.mason:${PATH}" MASON_DIR="`pwd`/.mason" mapbox_time "install_xcpretty" \ gem install xcpretty --no-rdoc --no-ri --no-document --quiet +mapbox_time "install_recent_git" \ +brew install git + mkdir -p ${KIF_SCREENSHOTS} diff --git a/scripts/ios/package.sh b/scripts/ios/package.sh index 4cd22d48e6..dd9e216ace 100755 --- a/scripts/ios/package.sh +++ b/scripts/ios/package.sh @@ -92,3 +92,23 @@ cp -pv LICENSE.md "${OUTPUT}/static" mkdir -p "${OUTPUT}/static/${NAME}.bundle" cp -pv platform/ios/resources/* "${OUTPUT}/static/${NAME}.bundle" cp -prv styles/styles "${OUTPUT}/static/${NAME}.bundle/styles" + +step "Creating API Docs..." +if [ -z `which appledoc` ]; then + echo "Unable to find appledoc. Consider installing it from source or Homebrew." + exit 1 +fi +DOCS_OUTPUT="${OUTPUT}/static/Docs" +DOCS_VERSION=$( git tag -l ios\* --sort -v:refname | sed -n '1p' | sed 's/ios-v//' ) +appledoc \ + --output ${DOCS_OUTPUT} \ + --project-name "Mapbox GL for iOS ${DOCS_VERSION}" \ + --project-company Mapbox \ + --create-html \ + --no-create-docset \ + --no-install-docset \ + --company-id com.mapbox \ + include/mbgl/ios +cd ${DOCS_OUTPUT} +ln -s html/index.html +cd ${OLDPWD} |