Morganamilo / paru

Feature packed AUR helper
GNU General Public License v3.0
6.09k stars 234 forks source link

Implement --print-format #866

Open luis-guimaraes-exoawk opened 1 year ago

luis-guimaraes-exoawk commented 1 year ago

Have you checked the readme and man page for this feature? Yes Have you checked previous issues for this feature? Yes

Is it possible to implement the --print-format flag from pacman as to make paru compatible with the Ansible module for managing pacman compatible package managers?

Source: https://docs.ansible.com/ansible/latest/collections/community/general/pacman_module.html#parameter-executable

thanks

Morganamilo commented 1 year ago

Would paru -Po foo work for you?

ThibaultNocchi commented 1 year ago

Hello, I don't think that's the case. The problem of this missing flag occurs when using paru as a pacman client with the Ansible package, as shown in the examples with yay: https://docs.ansible.com/ansible/latest/collections/community/general/pacman_module.html#examples

The error occurring when using paru instead is this:

TASK [common : install packages from AUR] *****************************************************************************************************************************************************
fatal: [host1]: FAILED! => {"changed": false, "cmd": ["/usr/bin/paru", "--noconfirm", "--noprogressbar", "--needed", "--sync", "--print-format", "%n %v", "i3lockmore-git"], "msg": "Failed to list package(s) to install", "stderr": "error: target not found: i3lockmore-git\n", "stderr_lines": ["error: target not found: i3lockmore-git"]}

The module passes this fixed argument --print-format and the format and it messes paru.

obvionaoe commented 1 year ago

Any progress on this? It would help me a lot, since I want to use Ansible to automatically install all of my AUR packages with paru.

I'd love to help, but I don't know a lot of Rust

Morganamilo commented 1 year ago

It's probably not too hard to implement. (Order.rs) does a similar thing. Though it's not a priority for me at the moment.

obvionaoe commented 1 year ago

hey, any updates regarding this?

aleksanderkrauze commented 1 year ago

@Morganamilo Hi. I would like to implement this feature. Would you be interested in accepting a PR once I finish?

Morganamilo commented 1 year ago

Yeah feel free to give it a shot.

dnlmsr commented 8 months ago

Hi everyone, any update on this?

readdeo91 commented 3 months ago

I'm having the same issue. Any other aur helpers that works?