aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorGabriel Arakaki Giovanini <mail@gabrielgio.me>2023-08-28 20:43:56 +0200
committerGabriel Arakaki Giovanini <mail@gabrielgio.me>2023-08-28 20:43:56 +0200
commit2b060e55e538a70f0edcd25d9a4c491a03d50149 (patch)
tree4b16ebea9d77ee5b587c2854466c6efd5c1e830c /main.go
parent6a97f945c72e3d7b6f34b906d9ae84f97dab5762 (diff)
downloadapkdoc-2b060e55e538a70f0edcd25d9a4c491a03d50149.tar.gz
apkdoc-2b060e55e538a70f0edcd25d9a4c491a03d50149.tar.bz2
apkdoc-2b060e55e538a70f0edcd25d9a4c491a03d50149.zip
feat: Add link to the commit for a given format
Diffstat (limited to 'main.go')
-rw-r--r--main.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/main.go b/main.go
index cfc56c4..3488c32 100644
--- a/main.go
+++ b/main.go
@@ -30,6 +30,7 @@ func fechIndex(url string) (io.ReadCloser, error) {
func main() {
url := flag.String("url", "", "Url to the APKINDEX.tar.gz")
output := flag.String("output", "index.md", "Output path")
+ repositoryFormat := flag.String("repository-format", "https://git.sr.ht/~gabrielgio/apkbuilds/tree/%s/item/apks/%s", "Template to build repository link")
flag.Parse()
tarStream, err := fechIndex(*url)
@@ -78,5 +79,5 @@ func main() {
panic("Error opening output file: " + err.Error())
}
- templates.WriteMarkdownTemplate(file, entries)
+ templates.WriteMarkdownTemplate(file, entries, *repositoryFormat)
}