Comments

This profile is from a federated server and may be incomplete. Browse more on the original instance.

notabot, to linux in Is there such a thing as split-screen grep?

Tmux is a very helpful terminal multiplexer, meaning it can split your terminal into multiple panes. So, create two side by side panes, then one way of doing it is:

  • on the left, run your cmd | tee >(grep ‘denied’ > error.log)
  • on the right, run tail -f error.log

The tee process takes it’s standard in, and writes itbto both standard out, so you see all the lines, and the path it’s been given. The >(…) operator runs the grep in a subprocess, and returns the path to it’s standard input pipe, so grep receives every line, and writes the denied lines to a log file which you display with tail in the other pane.

Rather than using a file for error.log you could also use a named pipe in much the same way.

notabot, to linux in TIL that operating system Linux is an example of anarcho-communism

I think even he realized his tocicity was a problem a few years ago, so he took time out to work on that and seems much more balanced now.

notabot, to science_memes in Memory Soup

I’m not an expert, but there’s a good overview of the process here: Nat Geo. You can de-paywall it at the usual places. They describe it more as “an organised broth full of chunky bits” as some organs don’t break down.

It’s a fascinating process either way.

notabot, to comicstrips in "Margaret" by Jim Benton

How else does Death guarantee a steady supply of full sized Snickers? The arrangement works for both of them.

notabot, to lemmyshitpost in ♫♪♫♪ The Day My Waymo Said Goodbye ♫♪♫♪

Ford has already patented the concept of a car repossesing itself if you fall behind on payments.

notabot, to memes in Anyways

All of the little provocations throughout this thread have been enough to make me twich, but this is the one that pushed me over the edge. I’m this close to printing out your comment just so I can correct it!

notabot, to lemmyshitpost in ♫♪♫♪ The Day My Waymo Said Goodbye ♫♪♫♪

I can see certain benefits, but as the parent poster mentions, what happens if there’s a child on the car, or, indeed, you’ve left something else important in it when it drives off. Surely it’s better for it just not to start, and keep a human in the loop for returning it.

notabot, to memes in Anyways

Aaarrgghh! I was just calming down, and now the twitching is back! Nurse! Nurse! I need my dried frog pills, someone is doing terrible things to the English language online.

notabot, to science_memes in Oxygen.

I second the recommendation, it’s a great story. The writing isn’t perfect, but it’s absorbing and there’s plenty of good world building and characters.

notabot, to comicstrips in "Margaret" by Jim Benton

Oh, I’m sure that, once word gets out, everyone will have a few Snickers or similar treats to hand at all times, sort of like how spirits would be sent to the afterlife with two coins for Charon, but a bit earlier in the process.

notabot, to upliftingnews in Tumor-destroying sound waves receive FDA approval for liver treatment in humans

The sound waves are focused onto the tumor, so they only have enough energy to damage tissue there, and not anywhere else.

Think about focusing the sun’s rays through a magnifying glass; they’re only concentrated enough to burn at a very small area. The focused ultrasound is similar, although they’re probably using some form of phased array to get the equivalent effect.

notabot, to linux in TIL that operating system Linux is an example of anarcho-communism

That’s fair, but the result seems to be the same; he’s nowhere near as caustic when interacting with people as he used to be. I had quite a lot of sympathy with the message in most of his technical rants, but the delivery was counterproductive. If he’s changed that I think he’s done well.

notabot, to linux in Is there such a thing as split-screen grep?

Sorry for th slow answer, I’ve been away. There is a way, if it’s still useful to you:

First, create a named fifo, you only need to do this once:


<span style="color:#323232;">mkfifo logview
</span>

Run your rsync in one pane, with a filtered view in the second:


<span style="color:#323232;">tmux new 'rsync ...options... |& tee logview' ; split-window -h 'grep "denied" logview'
</span>

Replace …options… with your normal rsync command line.

That should give you a split view, with all the normal messages on the left, and only messages containing ‘denied’ on the right.

The |& makes sure we capture both stdout and stderr, tee then writes them to the fifo and displays them. split-window tells tmux to create a second pane, and display the output of grep.

notabot, to lemmyshitpost in ♫♪♫♪ The Day My Waymo Said Goodbye ♫♪♫♪

Thanks, that made me laugh enough to wake the cat. :)

notabot, to science_memes in Thermal Energy Intuition

As with so many problems, this one can be solved with a suitably large cannon. Why you’d want to fire cups of water into the stratosphere is left as an exercise for the interested reader.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • localhost
  • All magazines
  • Loading…
    Loading the web debug toolbar…
    Attempt #