Skip to content

Commit 30e0615

Browse files
committed
Added fields type and types description in the spec
Signed-off-by: Chin Yeung Li <[email protected]>
1 parent 10fc656 commit 30e0615

File tree

1 file changed

+87
-1
lines changed

1 file changed

+87
-1
lines changed

docs/source/specification.rst

Lines changed: 87 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
.. _specification:
22

33
===============================
4-
ABOUT File Specification v4.0.0
4+
ABOUT File Specification v4.0.1
55
===============================
66

77
Purpose
@@ -433,3 +433,89 @@ Some examples:
433433
.. code-block:: none
434434
435435
checksum_md5: f30b9c173b1f19cf42ffa44f78e4b96c
436+
437+
Fields Type
438+
-----------
439+
440+
Following are the types for the supporting fields (All the custom fields will be treated as **StringField**):
441+
442+
.. list-table::
443+
:widths: 10 10
444+
:header-rows: 1
445+
446+
* - Type
447+
- Fields
448+
* - AboutResourceField
449+
- | about_resource
450+
| ignored_resources
451+
* - BooleanField
452+
- | redistribute
453+
| track_changes
454+
| modified
455+
| internal_use_only
456+
* - BooleanAndTwoCharactersField
457+
- attribute
458+
* - FileTextField
459+
- | license_file
460+
| notice_file
461+
| changelog_file
462+
| author_file
463+
* - ListField
464+
- | license_key
465+
| license_name
466+
| spdx_license_key
467+
* - PackageUrlField
468+
- package_url
469+
* - SingleLineField
470+
- | name
471+
| version
472+
| license_expression
473+
| spdx_license_expression
474+
| declared_license_expression
475+
| other_license_expression
476+
| vcs_tool
477+
| vcs_repository
478+
| vcs_path
479+
| vcs_tag
480+
| vcs_branch
481+
| vcs_revision
482+
| checksum_md5
483+
| checksum_sha1
484+
| checksum_sha256
485+
| spec_version
486+
* - StringField
487+
- | description
488+
| notes
489+
| copyright
490+
| owner
491+
| contact
492+
| author
493+
* - UrlField
494+
- | download_url
495+
| homepage_url
496+
| notice_url
497+
| owner_url
498+
* - UrlListField
499+
- license_url
500+
501+
Type description
502+
----------------
503+
504+
- **AboutResourceField**: Path or list of path to the about resource.
505+
- **BooleanField**: An flag field with a boolean value. Validated value is False,
506+
True or None.
507+
- **BooleanAndTwoCharactersField**: Field with either a boolean value or
508+
character(s) value (at most 2 characters). Validated value is False, True,
509+
None or character value.
510+
- **FileTextField**: A path field pointing to one or more text files such as
511+
license files. The validated value is an ordered dict of path->Text or None
512+
if no location or text could not be loaded.
513+
- **ListField**: A field containing a list of string values, one per line. The
514+
validated value is a list.
515+
- **PackageUrlField**: A Package URL field. The validated value is a purl
516+
- **SingleLineField**: A field containing a string value on a single line. The
517+
validated value is a string.
518+
- **StringField**: A field containing a string value possibly on multiple lines.
519+
The validated value is a string.
520+
- **UrlField**: A URL field. The validated value is a URL.
521+
- **UrlListField**: A URL field. The validated value is a list of URLs.

0 commit comments

Comments
 (0)