When printing the upgrade menu, sort the repos in the order they are
defined in pacman.conf (or more technically, the order they are
registered in alpm). Packages in the same repo are still sorted
alphabetically.
If a repo is not in pacman.conf or the database query fails it will
fallback to alphabetical.
add22f5957 added error checks to all the
passToPacman commands. This makes `yay -Q nonexistantpackage` return
non 0 as it should. Annoyingly it also made yay print `exit status = n`
which is the error string from passToPacman calls. This error doesn't
add much and is quite annoying, expecially when calling pacman commands
like `-Q` or `-Si` where yay should be kind of 'hidden' and print just
like pacman does.
Now set the error string to "" for pacman commands and don't print an
error if it == "" (avoids empty line printed).
Also behave more like pacman when using `yay -Qu`.
We now mock a PGP key server to provide the keys used during the
testing, making it so that we do not need the Internet anymore for
the testing of the PGP key import feature.
--redownload is meant to only download the targets the user provides.
If the user enters aur/foo then Yay will find the package foo from the
aur, --redownload will see thats not what the user entered and skips the
download.
This makes it so after the dep searching is done, all db/ prefixes are
dropped.
Created .go/src which symlinks to vendor/. Running `make` now builds
yay using the packages in vendor. This can still be overiden by running
`make GOPATH=$HOME/go`
Even though the makefile calls git to get the version, that can be
overiden using `make MAJORVERSION=5 MINORVERSION=400`, skipping the call to git. This
allows building yay/yay-bin using the makefile
The yay binary is now always yay instead of taking the name of the
parent directory.
Added vet and fmt checks to `make test` for more checking.
Reordered some stuff, made sure the dependency order is correct. Any
command such as `make package` can be ran at any point, even after a
`make clean` instead of having to execute the correct make commands in
order.
Changed install form using `go install` to a traditional install. The
pkgbuilds can now use `make DESTDIR=$PKGDIR install`. Added uninstall to match.
One thing this commit does not do is have proper recepies which depend
on files instead of phonies. The reason for this is that it does not
play that well with go's build system. Go is smart enough to only
recompile needed files anyway.