« first day (2016 days earlier)      last day (3232 days later) » 

00:19
I just learned that David McKay died yesterday. He was only 48.
 
9 hours later…
09:31
I'm sorry, that should have been David MacKay.
 
11 hours later…
20:50
Apparently been too long since my last apt-get upgrade... taking a whole two minutes to download packages... (at 10MB/sec)
Hi Anthony. Do you know who MacKay is/was?
Not really
21:21
@derobert Ok.
 
1 hour later…
22:48
So, if I get output like:
borg list --short .
orwell-2016-04-17:03.02
orwell-2016-04-17:04.00
And I want to loop over those individual strings, what's the easiest way of doing that?
23:22
36
Q: What to do with the "rm -rf" hoax question

SvenIt turns out the the recent question regarding the misuse of rm -rf in Ansible was actually just a hoax in some kind of viral marketing effort. It become quite famous on various media and gathered a large number of views. Since I don't think we should allow ServerFault to be abused in such way...

What a surprise.
23:38
@MichaelHomer What a moron.
23:55
@FaheemMitha maybe I don't understand you correctly, but why not: for str in $(borg list --short .); do something with $str; done ?
@JeffSchaller Would that automatically save to an array?
it would not -- that's a loop, as requested :)
Well, borg list --short .returns a newline separated list.
Which needs to be processed, a line at a time.
but it would actually be a duplicate
In bash, I'd do: array=( $(borg list --short .) )
23:58
@Gilles I wasn't planning to ask it.
@JeffSchaller Yes, that's one way to go. I found:
9
Q: Store output of command into the array

Prakash V HolkarThis is command: pdc status -a 2>&1 | grep 'okay' It gives the following output [okay ]: you are currently listening: 33 [okay ]: you are currently listening: 22 [okay ]: you are currently listening: 11 I have written this command in shell scrip file. But I want to store the outpu...

There does seem to be a lot of duplication across these sites, doesn't there?
25
Q: How to loop over the lines of a file?

Tobias KienzlerSay I have this file: hello world hello world This program #!/bin/bash for i in $(cat $1); do echo "tester: $i" done outputs tester: hello tester: world tester: hello tester: world I'd like to have the for iterate over each line individually ignoring whitespaces though, i.e. the las...

@JeffSchaller works only if the output is whitespace-separated (not newline-separated) and doesn't contain any wildcards

« first day (2016 days earlier)      last day (3232 days later) »