Skip to content
Snippets Groups Projects
Verified Commit 5ad58ca9 authored by David Runge's avatar David Runge :chipmunk:
Browse files

Add documentation and JSON schema for .SRCINFO files

docs/repositories/source_repository.rst:
Explain .SRCINFO files in the context of the source repository and add
the JSON schema, which can be used to validate it.
parent 8e9e9ac3
No related branches found
No related tags found
1 merge request!142Add parser for .SRCINFO files/ data
......@@ -6,8 +6,8 @@ Source Repository
A source repository is a |version control repository|, that contains the
necessary files to build a package. At the bare minimum this includes a
|PKGBUILD| file, but may contain an install script as well as patches or other
arbitrary files.
|PKGBUILD| and a ``.SRCINFO`` file, but may also contain an install script as
well as patches or other arbitrary files.
Using |makepkg|, the sources are used to build a package, which can be
installed with |pacman|. With the help of |package splitting| it is possible to
......@@ -18,6 +18,75 @@ create more than one package from a single |PKGBUILD|.
Due to |dbscripts| and |makepkg| limitations it is currently not possible to
target more than one :ref:`binary repository` with a single |PKGBUILD|.
.. _srcinfo:
.SRCINFO
--------
The ``.SRCINFO`` files contained in a :ref:`source repository` are data
representations of the accompanying |PKGBUILD| files and as such describe the
sources of any :ref:`package` build from it.
The files are read and parsed and can be described by the :ref:`srcinfov1` JSON
schema.
.. _pkgbase section:
Pkgbase section
^^^^^^^^^^^^^^^
This section of a ``.SRCINFO`` file describes the data common to all packages in
the |PKGBUILD| (this is similar to how :ref:`outputpackagebase_schema`
describes the data common to a set of packages in a :ref:`management
repository`).
The section is read and parsed when reading :ref:`srcinfo` files and must
exist. It can be described by the :ref:`pkgbasesectionv1` JSON schema.
.. _pkgname section:
Pkgname section
^^^^^^^^^^^^^^^
This section of a ``.SRCINFO`` file describes the data of a single package in
the |PKGBUILD|, which is different from the common data described by the
:ref:`pkgbase section` (this is similar to how :ref:`outputpackage_schema`
describes the data of a single package in a :ref:`management repository`).
The section may occur multiple times, but must exist at least once. It is read
and parsed when reading :ref:`srcinfo` files and can be described by the
:ref:`pkgnamesectionv1` JSON schema.
.. _srcinfo json schema:
JSON schema
^^^^^^^^^^^
.. _srcinfov1:
SrcInfoV1
"""""""""
.. literalinclude:: ../schema/SrcInfoV1.json
:language: json
.. _pkgbasesectionv1:
PkgBaseSectionV1
""""""""""""""""
.. literalinclude:: ../schema/PkgBaseSectionV1.json
:language: json
.. _pkgnamesectionv1:
PkgNameSectionV1
""""""""""""""""
.. literalinclude:: ../schema/PkgNameSectionV1.json
:language: json
.. |version control repository| raw:: html
<a target="blank" href="https://en.wikipedia.org/wiki/Repository_(version_control)">version control repository</a>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment