Commit Graph

1248 Commits

Author SHA1 Message Date
morganamilo
0657f7e23f
Complete -f for -G and --print -> --show 2018-08-30 16:09:08 +01:00
morganamilo
29642d181f
Document -f for -G and --print -> --show 2018-08-30 16:09:00 +01:00
Cirelli
ae06ca2380
Fix typo 2018-08-30 17:02:20 +02:00
morganamilo
004595a396
Dont rm directories with -G unless using -f 2018-08-30 15:30:52 +01:00
Anna
070f103fb9
Merge pull request #674 from Morganamilo/shell
Update shell completion for --aururl
2018-08-30 11:35:19 +01:00
morganamilo
5996e28e32
Use tabs and use pacman-conf over config parsing
This makes our zsh completion more similar to pacmans. Making it easier
to view diffs between the two.
2018-08-30 11:32:14 +01:00
morganamilo
127c5e7cb9
Update shell completion for --aururl 2018-08-30 11:06:03 +01:00
digimokan
0a120132ec README grammar, spelling, rewording, organizing (#661)
* README grammar, spelling, rewording, organizing

- Add "Objectives" section to group objectives.
- Transform Objective/Feature section bullets into action phrases.
- Fix yay/yaourt/etc capitalization. Italicize and follow ArchWiki style.
- Clearly identify the two Install section options with similar wording.
- Reorganize and reword Contributing section.
- Fix wording in last Code Style section sentence.
- Fix misc FAQ wording.
- Use same style for all FAQ issue links.
- Change link in "skipping packages" FAQ item to ArchWiki partial upgrade.
- Fix FAQ aur-only/repo-only cmd example line-spacing.
- Remove yay -Pu example since it is a deprecated (and wrapped) option.

* Fixup remove trailing newline in README file

* Add warning about editing files in vendor/

* Fixup revert italicized project/program names

* Change obj to Yaourt-style interactive srch/inst

* Change obj to Minimal dependencies

* Remove the limit-to-pacman deps feature

* Revert init-install sentence, but add "alternatively"

* Add provide-handling bullet to features

* Revert aur/repo-only FAQ item to one line

* Format cmd line examples similar to man page format

* Revert interface-for-pacman objective

* Mention dep instead of just saying don't touch

* Merge gopath into the build stage

Setting the gopath is more of a note than a step. It is not required and
I would expect most people can simply ignore it.

* Reword dependencies section.

The contributing section should be information and say what dependencies
are needed. There's no need to tell the user how to install them, they
can figure that out themselves.

Also mention git as a dependency.

* Tweak headings and drop numbers

Similar to the last commit. The headings should be
informative "Code Style", not commanding "Check code".

* yay -> Yay

Be more consistent when writing Yay as a name.

* Use ### instead of #### in Contributing

These are real subheadings, #### looks too small.

* Add support section
2018-08-30 10:54:16 +01:00
Anna
5e23a2fc6b
Merge pull request #669 from Morganamilo/tests-aururl
Fix tests and document --aururl
2018-08-29 23:19:10 +01:00
morganamilo
92ff640a65
Document --aururl 2018-08-29 21:18:37 +01:00
morganamilo
c93b3fca9e
Fix tests 2018-08-29 21:15:01 +01:00
J Guerreiro
73a171f48c
Merge pull request #668 from Jguer/fix-650
Make hash an unsigned integer
2018-08-29 18:31:05 +01:00
Jguer
d0cb79de6b
Make hash an unsigned integer 2018-08-29 18:30:16 +01:00
J Guerreiro
acced8c440
Merge pull request #665 from Morganamilo/fix#664
Expand documentation for --devel
2018-08-28 20:22:40 +01:00
Anna
4c351bdad8
Merge pull request #666 from Morganamilo/rm-timeout
Remove the timeout warning for vcs checks
2018-08-28 04:39:43 +01:00
morganamilo
6894ddfd5c
Remove the timeout warning for vcs checks
This message is proving to be more misleading than helpful. For
git+https sources, many hosts seem to always timeout when trying
ls-remote over git:// but then succeed on https://. This leads to
a time out message being displayed even though the URL was queried
successfully on the second try.
2018-08-28 04:38:58 +01:00
morganamilo
d34ce70455
Expand documentation for --devel
Correclty say Git instead of GitHub
Brielfly explain how --devel checks for updates
Give an example of pacaur-like devel
2018-08-28 04:33:51 +01:00
J Guerreiro
31aca68980
Merge pull request #625 from Morganamilo/updatebashcompletion
Update bash completion
2018-08-23 13:55:58 +01:00
Anna
0a136a3932
Merge pull request #648 from kkjdroid/master
Fixed spelling errors
2018-08-20 17:13:46 +01:00
Kenny Jackson
b39f7494df Fixed spelling errors 2018-08-20 12:05:56 -04:00
Anna
261070bf9d
Merge pull request #646 from Morganamilo/fix#623
Correctly set config.AURURL after parsing flags
2018-08-19 05:56:54 +01:00
morganamilo
2f545c7fdc
Correctly set config.AURURL after parsing flags
And also honour aururl during -Pc
2018-08-19 05:53:32 +01:00
Anna
3ab8a92421
Merge pull request #645 from Morganamilo/fix#623
Add --aururl
2018-08-19 05:19:48 +01:00
morganamilo
0454e8918b
Add --aururl 2018-08-19 05:10:24 +01:00
Anna
23ff1e79df
Merge pull request #642 from Morganamilo/needed
skip build when package is up to date and --needed
2018-08-18 21:02:40 +01:00
Anna
024fefe702
Merge pull request #644 from Morganamilo/vendorupdate
Update vendored dependencies
2018-08-18 21:00:39 +01:00
morganamilo
c0f73c4f31
Update vendored dependencies 2018-08-18 20:57:39 +01:00
Anna
ebc4ef1c33
Merge pull request #643 from Morganamilo/cleanmenu
Only print the clean number menu when needed
2018-08-18 20:53:00 +01:00
morganamilo
0f324b37a6
Only print the clean number menu when needed
The input is only asked when needed, but the numbered package list was
still printed either way. This fixes it so the list is not shown unless
needed.
2018-08-18 20:50:20 +01:00
morganamilo
aca65e743a
parsePackageList: include pkgrel in version 2018-08-18 17:54:20 +01:00
morganamilo
907bf3a30e
skip build when package is up to date and --needed
Before --needed was left purerly to pacman. The problem with this is
that if a package is not in the cache, it will end up being build just
for pacman to skip over the install.

Now Yay will handle this and skip the build and install if --needed is
used. The inital clone and pkgver bumb is still donw.
2018-08-18 17:54:17 +01:00
Anna
19bf8e773c
Merge pull request #641 from Morganamilo/parallel-G
Use goroutines for fetching packages via -G
2018-08-18 17:18:01 +01:00
morganamilo
03fee7b7d5
Expand -G documentation 2018-08-18 17:14:07 +01:00
morganamilo
e547173d42
Use goroutines for fetching abs packages 2018-08-18 17:14:07 +01:00
morganamilo
8711562923
capture: strip whitespace on outputs 2018-08-18 17:14:03 +01:00
morganamilo
a8e4f18e6b
MultiError: add new lines between errors 2018-08-18 17:12:42 +01:00
morganamilo
a1edd09a52
Fixup getPkgbuildsFromABS
Make it output more similary to downloadPkgbuilds. Refactor to remove
all the indention.
2018-08-18 17:12:42 +01:00
morganamilo
cba56c3f9e
Use downloadPkgbuilds for -G 2018-08-18 17:12:42 +01:00
Anna
a37bbd851e
Merge pull request #637 from Morganamilo/refactorinstall2
Refactor install
2018-08-18 17:08:34 +01:00
morganamilo
b1ee03a7d8
getBases now wants a slice instead of a map
The one place this function is used, the caller converts its data to
a map just to getBases will accept it. Instead just allow it to take the
slice to begin with.
2018-08-18 17:05:12 +01:00
morganamilo
40776fa184
implement formatPkgbase as Base.String
Now that Base is its own type, it is much neater to have this as its
stringer function.
2018-08-18 17:05:12 +01:00
morganamilo
afee400662
Use formatPkgbase with getIncompatible
There was a possibly that getIncompatible could be broken when working
with split packages. After looking into it, this does not seem to be the
case, as long as we only work with pkgbases.

arch may be overriden inside of a package function. The global arch
array may be 'any' but package_foo could say arch=('x86_64'). If you
were running arm then should yay warn about this?

I have decided the answer is no. This is because makepkg doesn't care.
It would seem makepkg only checks the global arch array. This leads me
to believe that the global array should contain a the required arch.

Therefore the correct way to do the former example would be to declare
the global arch as 'x86_64' and then override package_bar with 'any'.

So all that we should do is properly use formatPkgbase to list all the
packages under the base.
2018-08-18 17:05:12 +01:00
morganamilo
cd21298355
Return srcinfos instead of using it as a parameter
Also, we do not do a pre and post pkgverbump pass anymore, so theres no
need to name it stale.
2018-08-18 17:05:12 +01:00
morganamilo
29fdf23f50
Remove unneeded code, consistent function names 2018-08-18 17:05:12 +01:00
morganamilo
43feb12c85
Merge handles.Aur and depOrder.Bases
depOrder.Aur contains the order in which AUR packages are to be
installed. While depOrder.bases contains the actual package data
organized by pkgbase.

deoOrder.AUR is kind of counterintuitive, as it only contains one
package from each package base.

For example if you were to install libc++{,abi,experimental},
depOrder.Aur would only contain one of those packages, which one
actually being quite random. depOrder.Bases[pkg.Pkgbase] will then be
looked up and everything under that slice would be installed.

This means that the only real use depOrder.Aur has, is to give the
pkgbase. So to cut out the middleman, lets merge .Aur and .Bases into
a single field.

Doing this has also heped to spot som subtle bugs:

Fix subtle split package errors.

The number menus now correctly list and respect (installed) for bases
that have atleast one of their packages installed.

Entering package names in number menus now always expects the pkgbase
name instead of the random package which happened to make it into .Aur.

--rebuild and --redownload correctly handles split packages.

formatPkgbase is also used more.
2018-08-18 17:05:12 +01:00
morganamilo
3dc350d3ac
Simplify formatPkgBase
Only pass the packages belonging to the desired pkgbase. Before our
entire list of every pkgbase had to be passed, as well as an example
package from the base we are looking for.

This lets use use formatPkgBase easier in other places outside of
install.

Many of the functions in install could also be simplified in a similar
way, although that has not been done in this commit.
2018-08-15 20:11:19 +01:00
Anna
0e40d9a3f6
Merge pull request #614 from Morganamilo/refactormain
Refactor main
2018-08-15 20:11:00 +01:00
morganamilo
339a014614
Go back to using os.Getenv
Most programs seem to take an empty string as being the same as unset.
Even if they are technically different. This makes it easier to unset
variables via `VARIABLE= yay --foo`.
2018-08-12 05:09:56 +01:00
morganamilo
febccaef3a
Reorder main
Split functions out into smaller, more simple chunks. Ensure the correct
order of things.

Before, initConfig() would also create config.BuildDirbefore
the command line flags have been applied, so yay would
try to mkdir what was in the config, ignoring the flag.
2018-08-12 05:09:53 +01:00
morganamilo
2fac9c036f
Refactor main.go to use one liner if err checks 2018-08-12 03:53:42 +01:00