118 Commits
Author SHA1 Message Date
github-actions[bot]andCopilot 7c18572d22 [repo-assist] fix: clean up ALPM lock on interrupt (#2962)
fix: clean up ALPM lock on interrupt

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-27 00:12:48 +02:00
Jo 15057c8dab misc(ci): add modernize linter and update versioning (#2870)
* add modernize linter

* lint unused

* update imports

* ignore agent info
2026-06-17 21:09:53 +02:00
Jo 3b3a2b1dcc fix: search filter hooking and multierror cleanup (#2868)
* fix search filtering pass along

* prepare inclusion 'modernize' linter and use errors.join instead
2026-06-17 19:34:33 +02:00
Jo 4dbf124c51 feat(lua): add search filter and post install hooks (#2867)
* search filter and post install

add examples

* add tag
2026-06-16 23:35:18 +02:00
Jo 421b65bf43 feat: Add UpgradeSelect hook, logging and security example (#2855)
* add upgrade hook structure

* remove extra field

* feat: Add UpgradeSelect hook logging and security example

Add yay.log API to UpgradeSelect hooks for informational and warning messages.

- Add yay.log.info() and yay.log.warn() for hook logging
- Add doc/examples/recently_modified.lua: practical example to pre-exclude
  recently-modified AUR packages (supply chain attack mitigation)
- Update doc/init.lua with improved UpgradeSelect example
- Update doc/lua.md with logging API documentation
- Refactor autocmd and load modules for cleaner log integration
- Add comprehensive unit tests for logging functionality

* lint
2026-06-15 15:25:40 +02:00
Jo 1501438fba AUR: Add AURPreInstall hooks (#2854)
* add lua hooks on aur package installs

* add abort command to differentiate errors and aborts

* u
2026-06-15 13:31:13 +02:00
Jo ecae3e601e Add Lua configuration support (#2845)
* lua opt trial

* go mod tidy
2026-06-09 00:31:26 +02:00
Jo ac83d3fb06 Switch to JaroWinkler distance and reweight package search scores (#2840)
fix(query): use JaroWinkler distance and reweight metric components

Switch from Hamming to JaroWinkler distance for package name matching,
as JaroWinkler handles variable-length strings and gives a prefix-match
bonus better suited to package search.

Reweight the score components from sim*0.50 + simDesc*0.20 + popularity*0.30
to sim*0.35 + simDesc*0.15 + popularity*0.50 to better surface popular
packages when name similarity is moderate.

Roll back the unreleased version target from 13.0.0 to 12.6.0 to align
with the next minor release after v12.5.7.

Fix scanner.Err() check in parseStdin to surface I/O errors that were
previously silently dropped.
2026-06-07 18:16:46 +02:00
Jo 50c8291a1e Revert: ini addition to figure out a better customizable system (#2836)
* Revert "feat(ini): support ini config (#2774)"

This reverts commit 3e3d5aa111.

* use base-devel

* fix lint

* fix lint

* fix lint
2026-06-06 23:56:45 +02:00
JoandCopilot 3e3d5aa111 feat(ini): support ini config (#2774)
* support ini config

* support user ini config

* Update pkg/settings/ini.go

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-30 16:07:24 +01:00
Jo b2dfa0c56f chore(migration): default to "" as sortBy to keep existing behavior (#2768)
* bump builtin version

* add sortby migration to keep current user behavior
2026-01-22 10:28:47 +01:00
Jo 15c0597562 Build: Build without install with -B . (#2684)
* remove deprecated --tar flag and add --gitflags

Built without installing with -B

fix git tests gitBin

align with next

* fix order of ops
2025-12-22 15:22:10 +01:00
JoandCopilot 8ab3652846 Fix locale initialization logic (#2619)
* Fix locale initialization logic

* add comment

* Update main.go

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update GitHub Actions workflow for testing

* Update GitHub Actions workflow to allow artifact overwrite

* Update GitHub Actions workflow to allow artifact overwrite

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-06 18:16:47 +02:00
Jo 0b5f5f0ccd fix(main): return 1 exit code on panic (#2590) 2025-03-09 22:59:50 +01:00
Joey Holtzman d02c45e5b6 Remove deprecated flags in favor of boolean flags (#2350) 2024-01-25 16:03:47 +01:00
Joey Holtzman 8d773aa6a3 Remove deprecated warning when using -yc together (#2347) 2024-01-24 16:11:51 +01:00
Joey Holtzman d368f99be0 feat(yay): add boolean flags (#2285)
* feat(yay): add boolean flags

This feature now allows users to specify --<option>=<bool value> instead
of using --<option> and --no<option>. Specifying nothing results in the
boolean value being true. The flags prefixed with `no` are deprecated.

* chore(args): Print warning when using deprecated flags

* chore(yay): Update man page for deprecated options and add examples of
boolean flags being used
2023-09-27 12:36:57 +02:00
Jo 8916cd174b refactor(yay): move cfg inside of runtime (#2259)
* rework relationship between runtime and cfg

* separate runtime from cfg

* simplify instantiation logic

* move installer to appropriate package

* move operator to sync package

* add tests for srcinfo service

* consolidate srcinfo service in sync

* add logger to srcinfo

* add logger to preparer

* remove unused text functions

* remove remaining text.* from srcinfo

* remove global logger parts

* remove global org method exports

* remove global logger

* move text->input

* add rule to prevent fmt.Print

* update golangci go version

* remove outdated FAQs

* remove outdated FAQs
2023-08-06 21:39:41 +02:00
Jo e28319fece chore(yay): lift legacy engine (#2189)
* remove legacy engine

* remove legacy dep handlers

* use prepare for gendb

* remove unused method

* remove aur client old interface

* remove unused menu fns

* remove inactive upgrademenu option

* unexport printInfo
2023-05-24 08:22:18 +00:00
Jo 9641d2a608 chore(yay): add warning for yay -c (#2181)
add warning for yay -c
2023-05-22 22:02:14 +00:00
Jo a64180464b chore(man): fix wording on operation order to make it more clear (#2088)
fix wording on operation order to make it more clear
2023-04-06 16:49:18 +00:00
Jo d13bdb0ce1 feat(search): improve exact match for separate source (#2044)
* unify query builder

* remove uneeded code

* reorganize code
2023-04-02 00:23:02 +00:00
Jo 5d1c54413c fix(query_builder): use correct aur client for mixed query builder (#2041)
* use same repo search as pacman

use logger child from runtime

* use common interface for aur clients
2023-04-01 10:33:05 +00:00
Jo 7bc4a666e6 refactor(runtime): Build runtime after cmdargs parsing (#1965)
* extract runtime building from cfg

* respect AURRPCURL

* use -Syu if there are no targets, allows to pass extra options

* one more step towards removing runtime from cfg
2023-03-13 08:48:39 +00:00
Jo 3d5a43c294 chore(yay): bump version (#1949)
bump major
2023-03-07 21:04:06 +00:00
Jo e6ed869df1 chore(yay): remove global cfg (#1946)
remove global cfg
2023-03-05 21:58:18 +00:00
Jo fa2e726ca6 chore(text): use logger in new engine services (#1939)
* use logger in vcs

* use logger in query builder

* use logger in migrations
2023-02-25 19:03:27 +00:00
Jo 841395c318 feat(local_install): check PKGBUILD and .SRCINFO presence and generate .SRCINFO if necessary (#1938)
check build file presence and generate if needed
2023-02-25 17:44:24 +00:00
Jo 8d18f1be18 fix(new_engine): add aur client support to mixed source display (#1919)
* update aur client and use correct aur client

* add aur query client support for mixed source engine
2023-02-20 12:14:16 +00:00
Jo b8debd1ae7 chore(yay): fix small linting issues (#1885)
* replace context.TODO() in tests context.Background()

* remove mock TODOs

* prettier

* apply missing linting
2023-01-03 21:43:56 +00:00
Jo 28d90c981e feat(new engine): local install feature testing (#1867)
* make config into parameter

* test(new engine): local install test

* test(keys): fix test keys

* complete integration test for local install

* add simple mising mechanism
2022-12-29 12:34:53 +00:00
jguer 5aeb0d696c support contains 2022-11-13 23:53:37 +01:00
jguer 01721c816c refactor query builder to include AURClient 2022-11-13 14:29:00 +01:00
jguer bc4732e9e1 add debug mode 2022-09-20 00:11:10 +02:00
jguer f7286b25ae add local graph util 2022-09-06 23:25:44 +02:00
Jo 70695d7de7 chore(yay): avoid clearing panics in the main func (#1801) 2022-08-23 16:50:17 +00:00
jguer 1a52da5891 Make provides disabled by default. Add Migration to set provides to disabled 2022-08-05 22:55:54 +02:00
J Guerreiro e4a1f018ea feat(search): Add fuzzy name matching and mixed sources (#1719)
* fix(alpm): fix callback text

* feat(yay): Add mixed search result

* remove old result structs

* add option for controlling query builder

* only set query builder after parsing args

* add parser args

* update manpage

* write test for results

* write test for results

* mixed source test

* only sort 1 time with every mode
2022-03-06 23:48:15 +00:00
jguer 555d1ead95 chore(version): bump major version 2021-09-08 22:28:08 +02:00
jguer c8fcdeae5b feat(su): use alternative privilege elevators when sudo is not available
When sudobin/custom wrapper is not available try the following in order:

- sudo
- doas
- pkexec
- su
2021-08-31 02:17:27 +02:00
jguer b7f9a5e677 fix(install): fix missing error display in install 2021-08-21 16:17:19 +02:00
jguer 5be99d9bf0 chore(README): small reorganization of README 2021-08-20 18:33:52 +02:00
jguer e231b2b02d chore(yay): modernize exec commands 2021-08-14 00:10:43 +02:00
jguer cb4b57f6d8 chore(golangci): add new linters 2021-08-11 22:19:55 +02:00
jguer 172ee1f4e8 refactor(exe): port pacman calls to cmd_builder 2021-08-08 17:45:07 +02:00
jguer 1a2e5b9529 refactor(settings): move args to own package to allow pacman cmd builder 2021-08-08 17:45:07 +02:00
jguer 545ea772eb feat(aur): customize User Agent 2021-06-09 03:57:37 +02:00
x1b6e6 de113b87f3 Add support for multiple 'Architecture' values
This allows architecture to be multivalued. On x86-64 machines, this
could be something like:
    Architecture = x86-64-v3 x86-64

We use the first specified Architecture value in mirrorlist $arch
variable replacement, as this is backwards-compatible and sane.

More info:
https://git.archlinux.org/pacman.git/commit/?id=3179db108a83104d9de6d1d607f55f8118e92160

Signed-off-by: x1b6e6 <ftdabcde@gmail.com>
2021-05-04 08:43:56 +02:00
jguer 829f944659 fix(output): don't print exit status message 2021-03-18 22:40:37 +01:00
Julian Daube 348f2de85c fix(yay): mirror pacman return codes on run error
makepkg expects pacman-alikes to return 127 (missing dependency)
when called with -T as argument. yay does not behave like this since
it overwrite the return value with 1 in every case.

This commit will test for ExitCode errors and return the called
applications error code instead of 1, when possible. This gets yay
closer to be used as pacman alternative for makepkg with

```
PACMAN=yay makepkg -s
```

fixes  Jguer/yay#1455
2021-03-12 20:42:42 +01:00