guessica

package module
v1.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 24, 2022 License: BSD-3-Clause Imports: 13 Imported by: 3

README

Guessica

Build Go Report Card License

Update a PKGBUILD file by guessing the latest version number and finding the latest git tag and hash online.

logo

Installation (development version)

go get -u github.com/xyproto/guessica/cmd/guessica

Usage

Detect the latest version
guessica PKGBUILD
Detect the latest version and write the changes back to the PKGBUILD
guessica -i PKGBUILD

Note

The pkgver and source arrays will be guessed by searching the project webpage as defined by the url. For for projects on GitHub, github.com may also be visited.

General info

Stargazers over time

Stargazers over time

Documentation

Overview

Package guessica provides a way to guess the latest source URL for a PKGBUILD

Index

Constants

View Source
const VersionString = "Guessica 1.1.2"

VersionString contains the name and current version of Guessica

Variables

View Source
var SpecificSites = []string{"github.com", "gitlab.com", "sr.ht"}

SpecificSites adds extra support for examining specific URLs at certain git repository sites

Functions

func GuessSourceString

func GuessSourceString(pkgbuildContents, commonGitServer string) (string, string, error)

GuessSourceString is the function that is meant to be used from this source file It takes the contents of a PKGBUILD file and returns a new "source=" string. The new version number is guessed after looking online for a newer source. The git commit is included in the "source=" string, if possible. Returns the new pkgver and the new source. commonGitServer is often set to ie. "github.com"

func UpdateFile added in v1.1.0

func UpdateFile(filename string) error

UpdateFile will try to update the version in a given PKGBUILD filename

Types

This section is empty.

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL