You’re probably wanting [ -z "${VAR1}" -a -z "${VAR2}" ]. Note in bash that there are minor differences in how [ ] and [[ ]] tests are handled. You can pull up a handy cheat sheet of the operands on most distros by running man test, though you’ll need to read through the CONDITIONAL EXPRESSIONS section of man bash if you want to see the minor differences of the single vs double square bracket commands (mostly whether locale applies to string order, as well as whether operands are evaluated in numeric comparisons).
- 0 Posts
- 3 Comments
Joined 2 years ago
Cake day: September 16th, 2023
You are not logged in. If you use a Fediverse account that is able to follow users, you can follow this user.
dion_starfire@sh.itjust.worksto
Linux@lemmy.ml•Noone told me about systemctl suspend. I had to accidently learn about it from the arch pages. My battery is happy now, and you all will never be forgiven for your silence. That is all.
2·5 months agoAll legit. At the end of the day, both the commands that go through systemd and the direct cat something >/proc/… or cat something >/sys/… are all doing the same thing - telling the kernel to do some procedure.
There’s some settings stuff in /proc and /sys that you don’t want to tweak without knowing the effects, as they could break things in hard to fix ways, but for stuff like beeping or changing sleep states, the worst you’ll do is lock up your computer and need to reboot. And even that is rare unless the hardware really doesn’t like a particular sleep state.
Why pay $200/mo for cell service when companies like Mint and Cricket exist? You could be paying under $200/yr for that alone.