@@ -6,24 +6,24 @@ dependencies. They require special attention when making `xbps-src` templates.
66<!-- toc -->
77
88## Preface
9- Before talking about using git submodules in templates, few things have to be
9+ Before talking about using git submodules in templates, a few things have to be
1010considered:
1111
1212### Should the dependency be a submodule?
1313` xbps-src ` should handle all dependencies if possible. If the project depends on
1414a git submodule that is already packaged in ` void-packages ` and you are sure
15- that breakage won't occur, you should replace the submodule with actual packaged
16- dependency.
15+ that breakage won't occur, you should replace the submodule with an actual
16+ packaged dependency.
1717
1818If you choose this path, you will likely have to [ patch the build
1919system] ( ../packaging/j4-dmenu-desktop.md#when-their-build-system-is-broken )
2020or modify it in some other way to accept the packaged dependency. If you are
21- knowledgable of git submodules and upstream's build system, you could propose a
22- more packaging friendly way to handle dependencies [ to
21+ knowledgeable of git submodules and upstream's build system, you could propose
22+ a more packaging- friendly way to handle dependencies [ to
2323upstream] ( ../troubleshooting.md#notifying-upstream ) .
2424
25- But if the project is using a old version of the submodule or a customized one,
26- this likely won't be possible. The submodule also might not be packaged.
25+ But if the project is using an old version of the submodule or a customized
26+ one, this likely won't be possible. The submodule also might not be packaged.
2727
2828Header only libraries also [ don't really meet the quality
2929requirements] ( ../packaging/j4-dmenu-desktop.md#quality-requirements ) (but it
@@ -33,7 +33,7 @@ header only dependency as a git submodule is preferable in this scenario.
3333``` admonish info
3434If the submodule doesn't have tags, it can't be packaged, because it doesn't
3535meet quality requirements. If that is the case, it must be handled like a
36- submodule using methods described below.
36+ submodule using the methods described below.
3737```
3838
3939### Release archives
@@ -50,9 +50,9 @@ The proper official way to handle submodules is to add their archive to
5050` distfiles ` . ` git --recursive ` is not tolerable in templates. ` git ` usage in
5151general should be avoided in templates.
5252
53- To add the submodule to ` distfiles ` , you must have link to an archive containing
54- the submodule. To get that link, you need to know the version of the submodule
55- that is being used in the packaged release.
53+ To add the submodule to ` distfiles ` , you must have a link to an archive
54+ containing the submodule. To get that link, you need to know the version of the
55+ submodule that is being used in the packaged release.
5656
5757## Hunting for submodule archives
5858I will be showing this off on the
@@ -100,7 +100,7 @@ You should go to the directories where the submodules should be:
100100![ submodule commit] ( ../images/git_submodules/submodule_commit.png )
101101
102102You should also make sure that you are still checked out to the release. The
103- green box shouldn't contain ` master ` nor ` main ` . It should be a tag.
103+ green box shouldn't contain ` master ` or ` main ` . It should be a tag.
104104
105105Click on the submodule. You will be taken to the submodule in the commit it was
106106pinned to when the release of the template you're packaging (here ` gazou ` ) was
@@ -153,7 +153,7 @@ You should check all of the tags mentioned (there may be only a single one or
153153multiple like in the screenshot). We check them to see whether the examined
154154commit (here ` eb7ddab ` ) is tied to a tag.
155155
156- We first click on tag ` 1.5.0 ` :
156+ We first click on the tag ` 1.5.0 ` :
157157
158158![ tag 1.5.0] ( ../images/git_submodules/v1.5.0.png )
159159
@@ -206,12 +206,12 @@ https://github.com/Skycoder42/QHotkey/archive/refs/tags/1.4.2.tar.gz
206206```
207207
208208This is the resulting archive. It might contain the commit hash if the submodule
209- is pointing to a untagged commit.
209+ is pointing to an untagged commit.
210210
211211You can now proceed with [ adding distfiles] ( #add-distfiles ) .
212212
213213### Using git
214- Go tho the root of the repository and get a git link. On GitHub, you can simply
214+ Go to the root of the repository and get a git link. On GitHub, you can simply
215215append ` .git ` to the URL to get a HTTPS link for cloning the repo. You can also
216216use the green "Code" button. Other hosting services might require a different
217217process to get the git link.
@@ -225,7 +225,7 @@ git clone --depth 1 --single-branch --branch <tag> <repo>
225225
226226This is faster than a full clone.
227227
228- You should check what submodules does the repo need . They are defined in
228+ You should check what submodules the repo needs . They are defined in
229229` .gitmodules ` in the root of the repository:
230230```
231231> cat .gitmodules
@@ -268,12 +268,12 @@ You now have to construct the archive link. The following instructions are valid
268268for GitHub only, you will have to adjust it if the package isn't hosted on
269269GitHub.
270270
271- Tagged archive link looks like this:
271+ A tagged archive link looks like this:
272272```
273273https://github.com/<repo owner>/<repo name>/archive/refs/tags/<TAG>.tar.gz
274274```
275275
276- Untagged archive link looks like this:
276+ An untagged archive link looks like this:
277277```
278278https://github.com/<repo owner>/<repo name>/archive/<COMMIT>.tar.gz
279279```
0 commit comments