• AppleDoc的安裝使用


     前言,還是那句話,新手按照濤叔下面畫黃色的步驟順序執行就好了,不要問為什麼。

    一、安裝(注意,濤叔事先已經下載了appledoc)

    1、找到下載的appledoc目錄

    $ cd /Users/libotao/DevSource/iOS/appledoc 

    2、運行安裝

    $ sudo sh install-appledoc.sh 

    libotaodeMacBook-Pro:~ libotao$ cd /Users/libotao/DevSource/iOS/appledoc 
    
    libotaodeMacBook-Pro:appledoc libotao$ sudo sh install-appledoc.sh 
    
    Password:
    
    Building...
    View Code

    3、執行

    appledoc --project-name myproject --project-company "surge" --company-id www.surge --output ~/doc  ./Appledoc練習

    命令說明:

    --project-name "項目名稱"

    --project-company "公司名稱"

    --company-id "工程ID"

    --output "生成輸出結果"

    ./Appledoc練習  "這個是要掃描的路徑"

     

    生成文檔的名稱是  company-id   +   project-name

    生成的文档会自动存放在Xcode默认的文档目录里: 

    ~/Library/Developer/Shared/Documentation/DocSets

    那麼運行結果如何呢?截圖如下:

     

    文檔中內容如下:(創建信息等)

     

    Documentation set was installed to Xcode!
    
    Path: /Users/libotao/Library/Developer/Shared/Documentation/DocSets/www.surge.myproject.docset
    Time: 2015-04-17 19:09:35 +0000
    View Code

     

    ====================================================================

    擴展﹣﹣》查看幫助:

    對命令行不熟悉的朋友,下面有簡便寫法:

     

    appledoc --help

    libotaodeMacBook-Pro:~ libotao$ appledoc --help
    Usage: appledoc [OPTIONS] <paths to source dirs or files>
    
    PATHS
      -o, --output <path>                     Output path
      -t, --templates <path>                  Template files path
          --docset-install-path <path>        DocSet installation path
      -s, --include <path>                    Include static doc(s) at path
      -i, --ignore <path>                     Ignore given path
      -x, --exclude-output <path>             Exclude given path from output
          --index-desc <path>                 File including main index description
    
    PROJECT INFO
      -p, --project-name <string>             Project name
      -v, --project-version <string>          Project version
      -c, --project-company <string>          Project company
          --company-id <string>               Company UTI (i.e. reverse DNS name)
    
    OUTPUT GENERATION
      -h, --create-html                       [b] Create HTML
      -d, --create-docset                     [b] Create documentation set
      -n, --install-docset                    [b] Install documentation set to Xcode
      -u, --publish-docset                    [b] Prepare DocSet for publishing
          --html-anchors <string>             [*] The html anchor format to use in DocSet HTML.
          --clean-output                      [b] Remove contents of output path before starting !!CAUTION!!
    
    OPTIONS
          --keep-intermediate-files           [b] Keep intermediate files in output path
          --keep-undocumented-objects         [b] Keep undocumented objects
          --keep-undocumented-members         [b] Keep undocumented members
          --search-undocumented-doc           [b] Search undocumented members documentation
          --repeat-first-par                  [b] Repeat first paragraph in member documentation
          --preprocess-headerdoc              [b] Preprocess header doc comments - 10.7 only!
          --print-information-block-titles    [b] Print title of information blocks. "Note:", "Warning:", etc.
          --use-single-star                   [b] Use single star for bold marker
          --merge-categories                  [b] Merge categories to classes
          --merge-category-comment            [b] Merge category comment to class
          --keep-merged-sections              [b] Keep merged categories sections
          --prefix-merged-sections            [b] Prefix merged sections with category name
          --explicit-crossref                 [b] Shortcut for explicit default cross ref template
          --use-code-order                    [b] Order sections by the order specified in the input files
          --crossref-format <string>          Cross reference template regex
          --exit-threshold <number>           Exit code threshold below which 0 is returned
    
    WARNINGS
          --warn-missing-output-path          [b] Warn if output path is not given
          --warn-missing-company-id           [b] Warn if company ID is not given
          --warn-undocumented-object          [b] Warn on undocumented object
          --warn-undocumented-member          [b] Warn on undocumented member
          --warn-empty-description            [b] Warn on empty description block
          --warn-unknown-directive            [b] Warn on unknown directive or format
          --warn-invalid-crossref             [b] Warn on invalid cross reference
          --warn-missing-arg                  [b] Warn on missing method argument documentation
          --warn-unsupported-typedef-enum     [b] Warn on unsupported typedef enum
    
    DOCUMENTATION SET INFO
          --docset-bundle-id <string>         [*] DocSet bundle identifier
          --docset-bundle-name <string>       [*] DocSet bundle name
          --docset-desc <string>              [*] DocSet description
          --docset-copyright <string>         [*] DocSet copyright message
          --docset-feed-name <string>         [*] DocSet feed name
          --docset-feed-url <string>          [*] DocSet feed URL
          --docset-feed-formats <values>      DocSet feed formats. Separated by a comma [atom,xml]
          --docset-package-url <string>       [*] DocSet package (.xar) URL
          --docset-fallback-url <string>      [*] DocSet fallback URL
          --docset-publisher-id <string>      [*] DocSet publisher identifier
          --docset-publisher-name <string>    [*] DocSet publisher name
          --docset-min-xcode-version <string> [*] DocSet min. Xcode version
          --docset-platform-family <string>   [*] DocSet platform familiy
          --docset-cert-issuer <string>       [*] DocSet certificate issuer
          --docset-cert-signer <string>       [*] DocSet certificate signer
          --docset-bundle-filename <string>   [*] DocSet bundle filename
          --docset-atom-filename <string>     [*] DocSet atom feed filename
          --docset-xml-filename <string>      [*] DocSet xml feed filename
          --docset-package-filename <string>  [*] DocSet package (.xar,.tgz) filename. Leave off the extension. This will be added depending on the generated package.
    
    MISCELLANEOUS
          --logformat <number>                Log format [0-3]
          --verbose <value>                   Log verbosity level [0-6,xcode]
          --version                           Display version and exit
          --help                              Display this help and exit
    
    ==================================================================
    [b] boolean parameter, uses no value, use --no- prefix to negate.
    
    [*] indicates parameters accepting placeholder strings:
    - %PROJECT replaced with --project-name
    - %PROJECTID replaced with normalized --project-name
    - %VERSION replaced with --project-version
    - %VERSIONID replaced with normalized --project-version
    - %COMPANY replaced with --project-company
    - %COMPANYID replaced with --company-id
    - %YEAR replaced with current year (format yyyy)
    - %UPDATEDATE replaced with current date (format yyyy-MM-dd)
    - %DOCSETBUNDLEFILENAME replaced with --docset-bundle-filename
    - %DOCSETATOMFILENAME replaced with --docset-atom-filename
    - %DOCSETPACKAGEFILENAME replaced with --docset-package-filename
    
    ==================================================================
    Find more help and tips online:
    - http://appledoc.gentlebytes.com/
    - http://tomaz.github.com/appledoc/
    
    ==================================================================
    appledoc uses the following open source components, fully or partially:
    
    - DDCli by Dave Dribin
    - CocoaLumberjack by Robbie Hanson
    - ParseKit by Todd Ditchendorf
    - RegexKitLite by John Engelhart
    - GRMustache by Gwendal Roué
    - Discount by David Parsons
    - Timing functions from Apple examples
    
    We'd like to thank all authors for their contribution!
    View Code

    查看文檔中的命令:發現有漸變寫法 (-o)  == (--output)

    PATHS

      -o, --output <path>                     Output path

    PROJECT INFO

      -p, --project-name <string>             Project name

      -c, --project-company <string>          Project company

          --company-id <string>               Company UTI (i.e. reverse DNS name)

     

    上面例子中生成使用的命令:

    appledoc --project-name myproject --project-company "surge" --company-id www.surge --output ~/doc  ./Appledoc練習

    修改為

    appledoc -p myproject -c "surge" --company-id www.surge -o ~/doc  ./Appledoc練習

     

  • 相关阅读:
    js 字符中 带 函数 再传对象参数
    window server 2012 II8 假陌生 碰到的问题
    IIS 下载文件 报错“401
    easyui使用时出现这个Uncaught TypeError: Cannot read property 'combo' of undefined
    eclipse+gnuarm+使用报错
    mini2440:通过JLink烧写BootLoader到Nor Flash
    在Linux中搭建一个FTP服务器
    SPFA模板
    Bellman_ford模板
    前向星&链式前向星
  • 原文地址:https://www.cnblogs.com/surge/p/4436534.html
Copyright © 2020-2023  润新知