BuildInformation
Description
- Derived from
Abstract base for classes that represent build information of a module.
- See also
Public / Constructors
Load
Load the given module descriptor file.
A module descriptor file is a text file in CharacterEncoding.UTF_8 encoding which conforms to the following Grammar:
descriptor := module-name lb version-major lb version-minor lb build-date ; build-date := digit[4] '/' digit[2] '/' digit[2] ; lb := '\r' '\n'? | '\n' ; module-name := name ; version-major := number ; version-minor := number ; name := ]\n\r[+ ; number := digit+ ;
The following is an example for a module named MyModule
with the version0.9
:
MyModule 0 9 2024/01/13
- IOException
-
If an I/O error has occurred.
- ValidatingException
-
If the file content is malformed.
- See also
Public / Methods
Generate
Updates the BuildInformation implementation class of a code module and optionally the module descriptor file as well.
The given directory in is expected to contain a module descriptor file named BuildInformation.txt
(see Load). The BuildInformation implementation class will be written to the file named BuildInformation_Module_Name.cs
. If present, the Properties/AssemblyInfo.cs
file will be updated via UpdateAssemblyInfo.
- IOException
-
If an I/O error has occurred.
- ValidatingException
-
If the module descriptor file is malformed.
- See also
UpdateAssemblyInfo
Updates the given AssemblyInfo.cs
file.
The AssemblyTitleAttribute
and AssemblyVersionAttribute
entries in the file will be updated and the AssemblyFileVersionAttribute
will be removed.
- IOException
-
If an I/O error has occurred.
Public / Attributes
BuildDateString
The date of the build.
The string value stores the build date in the following format:
"YYYY/MM/DD"
.
ModuleName
Machine-readable and human-understandable name of the code module this build information is referring to.
VersionMajor
The major version number of the build.
Each time the major version number is increased, the minor version number is reset to 0
. Breaking changes and thus code migration can become necessary between major versions.
- See also
VersionMinor
The minor version number of the build.
The minor version number is incremented after applying improvements, bugfixes and patches which do not affect API compatibility, thus breaking changes will not occur and code migration is not necessary.
- See also