Jguer / yay

Yet another Yogurt - An AUR Helper written in Go
GNU General Public License v3.0
11.12k stars 362 forks source link

Add option for always accepting answers in English/Latin script #1410

Closed homocomputeris closed 1 year ago

homocomputeris commented 3 years ago

Is your feature request related to a problem? Please describe. pacman commands are typed in Latin script/English. yay prompts in the alphabet sen in the locale. It's very inconvenient. That's an example:

$ LC_ALL=en_US yay -Scc                  
/bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_US)

Cache directory: /var/cache/pacman/pkg/
:: Do you want to remove ALL files from cache? [y/N] y
removing all files from cache...

Database directory: /var/lib/pacman/
:: Do you want to remove unused repositories? [Y/n] y
removing unused sync repositories...

Каталог сборки: /home/nik/.cache/yay
==> Вы хотите удалить все пакеты AUR из кэша? [Д/н] y

Layout switching here shouldn't be necessary:

==> Вы хотите удалить все пакеты AUR из кэша? [Д/н] y

just ask always [Y/n]

Describe the solution you'd like Always accept answers in Latin/English.

Describe alternatives you've considered pikaur

Jguer commented 3 years ago

I find hard to justify this behavior as pacman does follow locale for this behaviour (ex: env LANG=pt_PT.utf8 yay -Scc) , is it a non-latin specific on pacman?

homocomputeris commented 3 years ago

In my Arch, pacman itself always prompts in English. I'm quite sure I haven't configured Pacman to do that. But if I have, Yay should follow that config.

$ env LANG=pt_PT.utf8 yay -Scc 

Cache directory: /var/cache/pacman/pkg/
:: Do you want to remove ALL files from cache? [y/N] 

Database directory: /var/lib/pacman/
:: Do you want to remove unused repositories? [Y/n] 
removing unused sync repositories...

Diretório de compilação: /home/nik/.cache/yay
==> Quer remover todos os pacotes AUR da cache? [S/n] n
$ sudo \pacman -Suy
:: Обновление баз данных пакетов...
 core не устарел
 extra не устарел
 community               5,2 MiB  11,0 MiB/s 00:00 [######################] 100%
 xyne-x86_64 не устарел
 sublime-text не устарел
 pnsft-pur не устарел
:: Запускается полное обновление системы...
разрешение зависимостей...
проверка конфликтов...

Пакеты (33) ca-certificates-mozilla-3.58-2  chromium-86.0.4240.183-1
            colord-1.4.5-1  colord-sane-1.4.5-1  enchant-2.2.11-2  gdm-3.38.2-1
            iptables-1:1.8.6-1  libgdm-3.38.2-1  libinput-1.16.3-1
            libixion-0.16.1-1  liborcus-0.16.1-1  libreoffice-fresh-7.0.3-2
            libwacom-1.6-1  libxml2-2.9.10-3  man-pages-5.09-1  net-snmp-5.9-1
            nodejs-15.1.0-1  nss-3.58-2  openal-1.21.0-1
            perl-alien-build-2.37-1  perl-alien-libxml2-0.17-1
            pipewire-0.3.15-1  python-argcomplete-1.11.1-1
            python-numpy-1.19.4-1  python-pikepdf-2.0.0-1  python-pytz-2020.4-1
            sane-1.0.31-3  sdl2-2.0.12-3  smbclient-4.13.2-1
            telegram-desktop-2.4.6-1  tldr-1.1.0-1  vulkan-icd-loader-1.2.158-1
            xorg-xkbcomp-1.4.4-1

Будет загружено:  264,54 MiB
Будет установлено:  842,68 MiB
Изменение размера:    0,34 MiB

:: Приступить к установке? [Y/n]
stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Jguer commented 3 years ago

This should be changed to follow exactly pacman

jdholtz commented 1 year ago

I'm trying to reproduce this error, but I cannot. I am using ru_RU.UTF-8 (I think that is the language used in the original post). This is the output I get from yay -Scc.

$ yay -Scc

Каталог для кэша: /var/cache/pacman/pkg/
:: Удалить ВСЕ файлы из кэша? [y/N]

Каталог базы данных: /var/lib/pacman/
:: Удалить неиспользуемые репозитории? [Y/n] n

Каталог сборки: /home/syntro/.cache/yay
:: Вы хотите удалить все пакеты AUR из кэша? [Y/n]

The last prompt is different from the one described in the original post (maybe this has to do with update translations?).

From my testing, both pacman and yay prompt the same for pt_PT and ru_RU (both latin and non-latin specific languages).

@homocomputeris does this issue still occur for you with the latest yay version?

homocomputeris commented 1 year ago

I'm sorry I can't reproduce because I don't have an Arch machine.

Jguer commented 1 year ago

Closing as non-reproducible I guess then, thanks for looking at it @jdholtz