« first day (3303 days earlier)      last day (1655 days later) » 

7:49 AM
Please suggest me a way to learn about building blocks of Linux.
 
8:33 AM
@Jesse_b well, the script I found noted that "This is the equation that works for the Gregorian calendar for years from 1582 through 9999". Any issues would probably come up first in the ends of the interval
 
9:31 AM
@StephenKitt %010d vs. %.10d... why would I want to use the latter?
And why does the latter produce zero-padding?!
The printf() spec, assuming awk uses the same semantics as C, does not say anything about zero-padding as far as I can see (but I can't deny that this is what awk appears to be doing).
I'm a bit surprised.
 
@StephenKitt. For d, i, o, u, x, X, a, A, e, E, f, F, g, and G conversion specifiers, leading zeros (following any indication of sign or base) are used to pad to the field width rather than performing space padding, except when converting an infinity or NaN. If the 0 and - flags both appear, the 0 flag is ignored. For d, i, o, u, x, and X conversion specifiers, if a precision is specified, the 0 flag shall be ignored. [CX] [Option Start] If the 0 and <apostrophe> flags both appear, the grouping characters are inserted before zero padding. For other conversions, the behavior is undefined.Ray Butterworth Oct 9 at 16:27
@StephenKitt, the .3d makes the intent much more obvious: An optional precision that gives the minimum number of digits to appear for the d, i, o, u, x, and X conversion specifiers. The 03d syntax dates back to the original 1970s version, and preserving backward compatibility has made its rules extremely complicated. — Ray Butterworth Oct 9 at 16:28
I was surprised too ;-).
 
Ah, yes, I just found it.
"if the converted value requires fewer
digits, it is padded on the left with zeros."
 
@StephenKitt Thanks for the quotes. And yes, it's mentioned in relation to d, not in relation to field width. That's why I did't see it at first.
And thanks for the edit too, obviously! :-)
 
@Kusalananda you’re welcome!
 
9:45 AM
For a short while I then wondered "but how would one print a short integer in a wide field without zero-filling?", but that's what the precision is for. I.e., printf("%10d\n", 34)
 
 
3 hours later…
12:37 PM
The user behind the (closed) question :here: is not very good at debugging. I've tried to help a bit, but it seems I'm not getting many of my points across.
 
One wonders why they’re switching from REXX to shell...
 
1:10 PM
@ilkkachu In my testing I changed line 26 from (_month*306001/10000) to (_month*306000/10000), (_month*306002/10000) and it still passed every time out of 1000 tries
I changed (_month*306001/10000) to (_month*306001/10001) and it still passes like 60% of the time
 
 
3 hours later…
4:35 PM
Please read and upvote the one positive Meta Stack Exchange post amidst the raging dumpster fire:
80
Q: To reach out: on Monica, the Lavender community, and the future of the Stack Exchange network

heatherOver the past weeks, the uproar has been vast, spanning the new Code of Conduct, Stack Exchange's conduct over the years, and more. Gallons of internet ink have been spilled by everyone involved, including myself. If you don't know me, I'm heather. I am a moderator on Quantum Computing Stack Exc...

3
 
@Kusalananda the width you mean.
 
@ilkkachu Possibly. Yes, the bit before the optional dot.
 
@Jesse_b if I could be bothered, I'd plot that equation and see how the error behaves. The only interesting term is that month*30.6, so it should be enough to just calculate one day in each month. Or well, there's only 3,6 million days between year zero and 9999, so one could compute it for them all... (but not with Excel though)
@Kusalananda yes :)
@Gilles while I'm happy there's someone who is still in their senses, that doesn't seem to help with how SE (the company) seems to be behaving, or the fact that the CoC seems to put one particular thing of all the issues in interpersonal communication in a huge spotlight.
 
@ilkkachu Oh, I'm unhappy about the company too. This isn't about the company, it's about the community.
 
yep.
 
4:50 PM
There are people who want to say that everyone who supports Monica supports transphobia. Both transphobes who say “everybody who supports Monica agrees with us, look how many supporters we have” and people who dislike or disagree with Monica who say “if you support Monica you're an evil transphobe”.
 
I think I'll just repeat what I said yesterday: it seems par for course in these ages that whatever the subject, everything gets polarized.
 
s/in these ages //. Humans are built this way, by and large.
Doesn't mean we have to like it.
 
5:17 PM
1
Q: Command to copy 20000 small files in 40 diferent directories

Ferrari21I have here a directory with about 20000 small files, and wish to copy them into 40 different directories, distributed by timestamp. Following is an example of what should be done, with 40 files divided in directories of 10 files each. The following criteria of number, or maybe minutes, with eac...

who the hell is upvoting this one?
(╯°□°)╯︵ ┻━┻
 
5:37 PM
That doesn't seem like such a bad question. It's a bit unclear on the details, but I've seen worse.
 
@ilkkachu Yeah I don't think it's terrible but it certainly isn't worth an upvote. I didn't think it was worth a downvote until it got so many upvotes
I really don't think it's answerable as written and so far every attempt OP has made to clarify has only made things even more confusing
Right now it's "I want to distribute 20000 files into 40 different directories containing only 10 files each, all with the same minute timestamp"
 
6:11 PM
In the below command, -i option is used to not error out of previous does not any input
docker-compose -p $1 -f $2 ps -q $3 | xargs -i ARGS docker inspect ARGS
What is the purpose of ARGS after -i oprion?
Is -i referring to ARGS saying that it can be empty
?
 
I think it's actually an invalid use?
Well. It should be equivalent to -I ARGS
 
yes is is -I
my bad
 
$ echo 'foo
bar
baz' | xargs -I ARGS echo ARGS leroy jenkins
foo leroy jenkins
bar leroy jenkins
baz leroy jenkins
> -I replstr
Execute utility for each input line, replacing one or more occurrences of replstr in up to replacements (or 5 if no -R flag is specified) arguments to
utility with the entire line of input. The resulting arguments, after replacement is done, will not be allowed to grow beyond 255 bytes; this is imple-
mented by concatenating as much of the argument containing replstr as possible, to the constructed arguments to utility, up to 255 bytes. The 255 byte
limit does not apply to arguments to utility which do not contain replstr, and furthermore, no replacement will be done on
 
6:38 PM
Ugh. Upgraded CODE and of course it broke its integration into Nextcloud.
This is your friendly reminder, never upgrade software. Security is for losers.
:-(
 
@derobert Definitely seems to be the mantra of apple users
People give microsoft update crap but I've never heard of microsoft update completely hosing a machine, every time apple comes out with a new update I hear stories of people's machines becoming completely unusable because of it
 
@Jesse_b Well, M$ has managed to do it before too. Far less often, though.
(Especially when you consider the size of the installed base)
Content Security Policy: The page’s settings blocked the loading of a resource at https://192.168.64.1:9980/loleaflet/2fc9aba/loleaflet.html?W…e=New%20Document.odt&lang=en&closebutton=1&revisionhistory=1 (“frame-src”). ... oh yeah! something has decided to leak out internal IPs!
 
6:57 PM
Ok. Got it working again. Appears now Nextcloud needs the external URL, not the internal one. Ok then.
 
 
2 hours later…
8:43 PM
Is it bad that I have a lot of xkcd strips memorised? As in, I can tell which one people refer to before actually looking at it.
 
@FaheemMitha It's probably fair to say that most of the users on this site have above average memorization abilities
 
9:43 PM
And surely above average hours spent reading xkcd.
 
 
1 hour later…
10:46 PM
No fair @Kusalananda: I can't answer that one because I use vscode :P
 
@Jesse_b ... and I use vim.
But Sublime is free so I installed just for the sake of that user.
It would have been easier if the JSON structure was documented somewher, but it isn't.
 
Well I didn't want to answer it that bad...
 
@Jesse_b I was bored. And now I'll go to bed.
 

« first day (3303 days earlier)      last day (1655 days later) »