Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support -q flag for quiet #96

Closed
ghost opened this issue May 31, 2017 · 3 comments
Closed

Support -q flag for quiet #96

ghost opened this issue May 31, 2017 · 3 comments

Comments

@ghost
Copy link

ghost commented May 31, 2017

Is this something that you're ever planning to do? Honestly, this would make this a lot more usable for me, because it'd let me do things like pacapt -R $(pacapt -Qsq blahstuff) which is a lot more intuitive than having to parse the output further. I know it'd require a bit of text manipulation, and that's not Bash's strong suite. (I'm honestly not sure why people write such large projects in Bash :P )

If this is something you plan to do, maybe you should add it to the automatically generated table. I really hope it is, as it'd make things a ton easier. You accept pull requests? You're probably a lot better at me at coding in Bash than I am, but I could give implementing this a try if no one else wants to.

@icy
Copy link
Owner

icy commented May 31, 2017

Hi @avrildev,

Thanks for your feedback. There is -q option but it doesn't work consistently: pacman -Qq works, but pacman -Qqs doesn't. I will take a look. I hadn't known there is pacman -Qqs operation until I read this post. My bad 🗡

What distro are you working on?

A lot of text processing can be done with bash, awk, sed, grep,... For complex things (as you see here https://github.com/icy/pacapt/blob/ng/bin/gen_tests.rb) I agree that bash is not enough. The truth is that I haven't seen any real problem with non-bash things in lib/* so far -- that's the source of pacapt power ;)

@ghost
Copy link
Author

ghost commented May 31, 2017

Most of my machines run stock Arch currently, but I use Ubuntu 16.04 for business-grade systems, and my Raspberry Pis run Raspbian. (Although I think Arch ARM could be entertaining to try out!)

Last time I tested pacapt, I had a Linux Mint 18.1 Serena install, which is of course basically Ubuntu. If it's testing you want, I'd be very happy to install a Debian/Ubuntu chroot/VM for testing. Or Fedora/CentOS for yum, but I can't promise I'll be able to debug very intelligently on those. :P

Also, I, ahem, don't currently know Ruby fluently. I've been working on learning it, but I wouldn't want to waste your time with pull requests for sloppy code. I actually didn't notice this project incorporated Ruby, but I can definitely see why you'd choose it. I've read that it's nearly as fast as Bash. And it's definitely much more readable, for me anyway!

Edit: Also should mention, there's a -Ssq operation too! It does pretty much what you'd expect. The -q modifier applies to anything that lists stuff, AFAIK.

@icy
Copy link
Owner

icy commented Jun 17, 2021

@ghost Sorry for the belated feedback. Should be fixed with #143. I'm closing this issue and sending new Pr.

@icy icy closed this as completed Jun 17, 2021
icy added a commit that referenced this issue Jun 17, 2021
icy added a commit that referenced this issue Jun 17, 2021
icy added a commit that referenced this issue Jun 17, 2021
icy added a commit that referenced this issue Jun 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant