`SLURP_ARGS` doesn't function when more than one argument is specified
Program
grimblast
Maintainers of the program
@fufexan
Bug or Regression?
Bug
Description
simply put, the code for passing custom cli args to slurp does not work: https://github.com/hyprwm/contrib/blob/1e531dc49ad36c88b45bf836081a7a2c8927e072/grimblast/grimblast#L238
fairly confident this never worked as bash just doesn't let you do this -- any argument after the first gets dropped when you try to pass it like this
as you can see here, only the first argument -d (show dimensions) is working, all of the others are nonfunctional.
How to reproduce
- set SLURP_ARGS with more than one argument separated by spaces
- see that any arguments after the first do not apply
Hyprland crash reports, program logs, images, videos
No response
Can you check whether quoting the variable makes it work?
Not working for me either, when I set $SLURP_ARGS to -b "#00000000" -c "#80808080" -w 2 (adding 's between that whole thing makes slurp $SLURP_ARGS not work).
Can you try https://github.com/hyprwm/contrib/tree/slurp_args?
I setup the nix flake with the following
hyprland-contrib = {
url = "github:hyprwm/contrib/?ref=slurp_args";
inputs.nixpkgs.follows = "nixpkgs";
};
And set SLURP_ARGS to -b "#00000000" -c "#80808080" -w 2 then did grimblast save area and it doesn't seem to work?
How did you set it? Seems to work for me with export SLURP_ARGS="-b "#00000000" -c "#80808080" -w 2"
Oh I set it locally with set in fish. Export works for me, thanks.
Great. I'll rebase that on main then.
https://github.com/hyprwm/contrib/commit/26c72abe70bf149684dee838618dbb388f54d27d
@fufexan Actually I have a question: how can I make it not add a white overlay?
-b #00000000
even with the SLURP_ARGS exported I still see a white overlay on the current app when I do grimblast save area.
Oh, that would be -B, according to man slurp.
Oh, thanks.