Wikipedia:Reference desk/Archives/Computing/2019 May 31

= May 31 =

* vs ? in cron
In my previous job, I had to work with cron scheduling. It became apparent that cron supports two "wild card" characters for units of time: * meaning "all" and ? meaning "any". What is the difference between them? J I P &#124; Talk 00:23, 31 May 2019 (UTC)


 * Generally, "?" means: match exactly one character; whereas "*" is any string (even empty). Bubba73 You talkin' to me? 01:17, 31 May 2019 (UTC)


 * Or you could look at man 5 crontab and see the right answer. In a crontab, "*" means "any value" for the applicable field.  (For example if the minutes, hours, day-of-the-month, month, and day-of-the-week fields are "0 * * * *", then the process will execute every hour on the hour.)  "?" means "some value" chosen at random.  (For example, "0 ? * * *" would mean to pick one of 00:00, 01:00, 02:00, etc. up to 23:00 and then execute the process every day at that time.)  The random choice for "?" is made when cron reads the crontab file.


 * At least, this is correct on the NetBSD system where I just read the man page. On my Linux system the corresponding man page does not mention "?".  --76.69.46.228 (talk) 02:52, 31 May 2019 (UTC)
 * We can do even better than the man page - we can read the source!
 * Out of the box, NetBSD uses Vixie cron, the most popular free software implementation that is largely compatible with the ancient ISC cron. A few esoteric versions of Linux default to GNU mcron.  To my knowledge, none of these support the "?" wildcard syntax.
 * Another program is anacron, which uses yet another syntax.
 * It's worth checking what version of cron you actually have installed - this is the sort of thing that can vary among common Linux and Unix distributions. Exotic versions of cron may have non-platform-portable features, so use them with caution!
 * On at least one BSD-like system - macOS - cron is gone, and job scheduling is now managed by launchd, which is configured in a totally different fashion using job control plist files. At least a few people say that cron is obsolete - for example, see this Google Tech Talk on launchd - and if you're running a Linux or BSD system, consider switching away from cron.  launchd on FreeBSD.  On pure linux, systemd is a modern replacement for cron, further documented in the systemd man page.  Most of the true Linuces opted not to adopt launchd, for reasons that are interesting mostly to system-software nerds.  But in any event, there are several very good reasons to stop using cron: there are a lot of subtle corner-cases that pertain to security, time-zones, cron schedule modifications, and multi-user systems, that all cause "weird" behaviors that are even weirder when you compare across implementations.  Fixing up these weird corner cases, and discouraging future use of crontabs, were among the reasons motivating the creation of launchd and systemd.
 * Nimur (talk) 05:07, 31 May 2019 (UTC)

Use of Galaxy phone while charging
A friend using a Galaxy phone has been told that she should not use the phone while it is charging. She also says she has a blank screen when charging and takes that to mean she cannot use it. Is she right? I use an iPhone and work often with the cable attached. Jmar67 (talk) 02:11, 31 May 2019 (UTC)
 * I have a Galaxy S8 and routinely use it while charging. Samsung seems to think it's fine as well, though it is a common misconception. Matt Deres (talk) 12:55, 31 May 2019 (UTC)

Need photo cropping app for Android 7.1.1
I would like to be able to trim off all the irrelevant parts of screen grabs from Google Maps I've uploaded to my phone. I could do it on the PC, using MS Paint, but that's awkward to use for cropping.I tried cropping it on my phone, but whatever app it's using is unacceptable. The first shortcoming is that the borders you manipulate to tell it where to crop are always black, which is obviously no good on a dark background. It should either use borders that reverse the color of the underlying pixels, or, if that's too CPU intensive, flashing between opposite colors would work, too, or just a dotted line with alternating colors. The even bigger shortcoming is that the cropped pic is fuzzy, even though when zoomed in on that same region on the original, it's a nice sharp pic. The image quality should not be changed in any way when I crop an image. I would also like to be able to change brightness and contrast, and invert all colors, but that's about all I need in a photo editor on my phone. For anything more, I'd edit it on PC. So, can anyone recommend an app for me ?

Also, the phone seemed to have 2 photo editing apps built-in, and it asked me which one I wanted to use, once, then never again. I'd also like to go back and try the other built-in app, but can't figure out how to do that. Phone is a ZTE ZFIVE C LTE (Z558VL). Thanks.

SinisterLefty (talk) 21:42, 31 May 2019 (UTC)


 * Well, since it looks like there's no decent cropping app, I'll do it on PC then download to the phone. Not convenient, but it works. Thanks anyway. SinisterLefty (talk) 22:13, 5 June 2019 (UTC)