The order of targets does somewhat matter. For example doing something
like 'pacman -S db1/foo db2/foo' should cause the second package to be
skipped.
The order of targets also effects in which order they are resolved. This
should make errors more reproducable if any ever occur.
Sort the provider menu alphabetically. Always ensure direct matches show
up first. This ensures hitting enter for the default value will always
be the same package that the user/dependency requested if an exact match
exists.
If a package is already installed pick that instead of providing a menu.
Ensure duplicates do not show up in the menu.
This is a rewrite of the dependency system, It aims to be cleaner
written, with a better idea of what is needed from the start, meaning
less new code being hacked on for things that were not thought about.
This version also aims to use as many small functions as possible, for
cleaner code and better testing.
Added dep.go:
general dependency functions
Added depPool.go:
Replacement of depTree, dependencies were never ordered so
a tree did not really make sense. Instead the term pool
makes more sense.
Added depOrder.go:
Replacement of depCatagories, This simply orders the
dependencies, dependencies are still catagorized as repo and AUR
but I believe this to be a better name
Added depCheck.go:
Replaces conflicts.go and also contains the missing dependency
code
This version is mostly the same as the old version with a few
improvments:
Missing packages will print the full dependency tree
Versioned dependency checking errors should be fixed
Make depends should be calculated properly
Experimental AUR provide searcher
This code has been added along side the old code for testing and is not
currently used by the install process. Once the install process is moved
to use this code, the old code will be removed.
Print the full descriptions of each news item.
The description is formatted as html, basic parsing is done to display
it properly. -q/--quiet can be used to diplay title only.
This commit also refactors the news related sructs into their own types
instead of being anonymous and moves the printing to its own .Print()
function.
Ensure aurWarnings will always be printed out in one block
use '->' for printing aur warnings and ignored upgrades
use '->' for conflict printing
use '->' for key importing
Say PGP keys not GPG keys
Add back green for input prompts
Use 4 spcaces over \t
To know what AUR packages need updating a rpc request is needed for all
packages. The dep tree is designed to cache everything to minimize the
amount of rpc requests. The downside of this is the dep tree ends up
with all sorts of packages in cache that it doesn't need. Then the
deptree tries to resolve deps for all of thoes packages.
By spliting the sysupgrade from the dep tree this stops this from
happening, it uses one more rpc request but also may lower the amount of
total rpc requests needed lated on.
This fixes a couple of tiny bugs such as triggering providers prompts
and printing AUR out of date messages for packages that are not going
to be installed.
This also fixes another display bug where repo packages from -Su would
not apear when printing the packages to be installed under [Repo].
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`.
-Qu now has AUR support, it functions identically to `-Pu` and may replace
it in the futre.
Aditionally the pacman options `-n` and `-m` are also supported to
filter out native and non native packages. Other flags are not supported
currently.
Using any other `-Q` will fallback to Pacman.
commit 5286f385 broke the alignment on -> in the upgrade menu.
This commit moves the function responsable for printing the upgrade menu
from upgrade.go to print.go, fixes the formating to how it was before
and changes the padding on the number to three digits instead of two.
This allows proper alignment on numbers >100 which is not unheard of.
Reformatted comments to have a space between // and the start of the
comment.
Added capital letters and punctuation.
Fixed most grammar and spelling mistakes.
Fixed date to yyyy/mm/dd.
Comments have been added to a couple of functions here and there
where I feel warrent some explanation. Hopefully this makes it a little
easier for people to contribute.
I commented on a couple of functions but my main focus is:
DepTree
DepCatagories
StringSet
Arguments
These are parts that have been mostly written by me and might seem
confusing without taking a while to study the code. Especially the first
two mentioned. They're a little complex, I'm not sure if they need to be
This is just how I came up with them. Hopefully helping other people
understand them will let them come up with improvments I did not see.
I'm not the best at explaining things but I did try my best here.
Add ( and ) to "installed" to match groups and out of date
Show popularity as well as voted in yogurt mode
Show download and install size in yogurt mode
Remove printing of white and black
Fix incorrect message on number menu
Yellow is now almost never used
Use `v` instead of `r` when printing version
show when a page was marked out of date on search and info
Note when installing CheckDepends are still refered to as MakeDepends.
They are both only needed during build time so technically that is
correct. I don't see much of a use creating a third field so I'm leaving
it as is for now.
This commit mostly focuses on merging the install() and upgradePkgs()
functions to be more integrated. Instead of both making their own aur
queries they now both combine theyre needes into one query. This gives
us a speed up and allows us to easily print orphands, misising and out
of date in one clean block.
Split packages are now grouped together when printing displaying the
package base and the packages inside of the base to beinstalled. If only
one packge is to be installed from a base and the package name matches
the base name print normally
Only build and install once per package base
Only ask questions once per package base for editing pkgbuils and clean
build