mirror of
https://github.com/Jguer/yay.git
synced 2024-11-07 09:37:22 +01:00
1.8 KiB
1.8 KiB
goPKGBUILD
A golang package for parsing Arch Linux .SRCINFO
files
(PKGBUILDs).
TODO
- Handle split PKGBUILDs like linux
- Try to parse maintainer from top of PKGBUILD
- Handle multiple dependency versions
- Add support for reading a
.SRCINFO
file directly - Update to pacman 4.2
Usage
Example usage
package main
import (
"fmt"
"github.com/mikkeloscar/gopkgbuild"
)
func main() {
pkgb, err := ParseSRCINFO("/path/to/.SRCINFO")
if err != nil {
fmt.Println(err)
}
for _, subPkg := range pkgb.Pkgnames {
fmt.Printf("Package name: %s", subPkg)
}
}
LICENSE
Copyright (C) 2016 Mikkel Oscar Lyderik Larsen
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.