在 php 和所有可用标签(如@author)中编写贡献 header 的最佳方式

Best way to write contributions header in php and all available tags like @author

我正在做一个 GitHub 项目 https://github.com/qzoke/isbn-converter 我想创造一个很好的贡献 header。所以这是我的问题:

  1. 所有变量或@author 之类的可用变量。

我知道的很少有:

@author
@license
@version
@package
@subpackage
  1. 展示价值的最佳方式,例如

很少使用

@author www.website.com

很少使用

@author name<email>

还有一些

@author name.
  1. 包和子包的名称应该如何命名。分包令人困惑,不知道我应该使用分包中的文件名还是相同的包名。

  2. 可以在里面写描述,关键词,投稿吗

  3. 引用许可证的最佳方式是什么,只需名称(如 GNU GPL v3.0)或名称+weblink 或 link 到本地副本或整个副本许可文本。

  4. 哪些文件应该有这样的 header ,只有 index.php 或 header.php 或其他所有文件。

  5. 以及 html 评论中包含的内容(如果有)。

根据 https://phpdoc.org/ documentation there is a number of tags recognised by the phpDocumentor listed at https://phpdoc.org/docs/latest/index.html.

示例来源 https://phpdoc.org/docs/latest/references/phpdoc/tags/author.html

Syntax: @author [name] [<email address>]

The @author tag can be used to indicate who has created Structural Elements or has made significant modifications to them. This tag MAY also contain an e-mail address. If an e-mail address is provided it MUST follow the author’s name and be contained in chevrons, or angle brackets, and MUST adhere to the syntax defined in section 3.4.1 of RFC5322.

您的所有观点都可以使用 PHPDoc 的文档来回答。

还有几个 PHPDoc 标签是:

@abstract
@access
@author
@copyright
@deprecated
@deprec
@example
@exception
@global
@ignore
@internal
@license
@link
@name
@magic
@package
@param
@return
@see
@since
@static
@staticvar
@subpackage
@throws
@todo
@var
@version

您可以在 https://en.wikipedia.org/wiki/PHPDoc

中找到更多信息