Skip to main content
edited title
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298

Why is Piping into less giving me aand editing: "cannot edit standard input" error. Workarounds?

I recently learned that if I page my files with less, I can press v and open the buffer in Emacs. This works as long as I have the environment variable $EDITOR set up correctly, which in my case I have it as:

export EDITOR='env TERM=xterm-256color emacs -nw'

The above gives me the ability to load emacs within the terminal that runs less.

However, the trick above does not work when piping commands to less. When doing this, less complains with the following message:

Cannot edit standard input (press RETURN)

My question is, why does this happen? But perhaps most importantly, is there any workaround to it?

Why is less giving me a "cannot edit standard input" error?

I recently learned that if I page my files with less, I can press v and open the buffer in Emacs. This works as long as I have the environment variable $EDITOR set up correctly, which in my case I have it as:

export EDITOR='env TERM=xterm-256color emacs -nw'

The above gives me the ability to load emacs within the terminal that runs less.

However, the trick above does not work when piping commands to less. When doing this, less complains with the following message:

Cannot edit standard input (press RETURN)

My question is, why does this happen? But perhaps most importantly, is there any workaround to it?

Piping into less and editing: "cannot edit standard input" error. Workarounds?

I recently learned that if I page my files with less, I can press v and open the buffer in Emacs. This works as long as I have the environment variable $EDITOR set up correctly, which in my case I have it as:

export EDITOR='env TERM=xterm-256color emacs -nw'

The above gives me the ability to load emacs within the terminal that runs less.

However, the trick above does not work when piping commands to less. When doing this, less complains with the following message:

Cannot edit standard input (press RETURN)

My question is, why does this happen? But most importantly, is there any workaround to it?

Why is less: giving me a "cannot edit standard input". Workarounds error?

added 4 characters in body
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298

less: "cannot edit standard input". Workarounds?

I recently learned that if I page my files with less, I can press v and open the buffer in Emacs. This works as long as I have the environment variable $EDITOR set up correctly, which in my case I have it as:

export EDITOR='env TERM=xterm-256color emacs -nw'

The above gives me the ability to load emacs within the terminal that runs less.

However, the trick above does not work when pipingpiping commands to less. When doing this, less complains with the following message:

Cannot edit standard input (press RETURN)

My question is, why does this happen? But perhaps most importantly, is there any workaround to itis there any workaround to it?

less: "cannot edit standard input"

I recently learned that if I page my files with less, I can press v and open the buffer in Emacs. This works as long as I have the environment variable $EDITOR set up correctly, which in my case I have it as:

export EDITOR='env TERM=xterm-256color emacs -nw'

The above gives me the ability to load emacs within the terminal that runs less.

However, the trick above does not work when piping commands to less. When doing this, less complains with the following message:

Cannot edit standard input (press RETURN)

My question is, why does this happen? But perhaps most importantly, is there any workaround to it?

less: "cannot edit standard input". Workarounds?

I recently learned that if I page my files with less, I can press v and open the buffer in Emacs. This works as long as I have the environment variable $EDITOR set up correctly, which in my case I have it as:

export EDITOR='env TERM=xterm-256color emacs -nw'

The above gives me the ability to load emacs within the terminal that runs less.

However, the trick above does not work when piping commands to less. When doing this, less complains with the following message:

Cannot edit standard input (press RETURN)

My question is, why does this happen? But perhaps most importantly, is there any workaround to it?

Tweeted twitter.com/#!/StackUnix/status/129047132698198016
added 12 characters in body
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298
Loading
added 34 characters in body; deleted 22 characters in body; edited body; added 23 characters in body; deleted 7 characters in body
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298
Loading
edited title
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298
Loading
added 28 characters in body
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298
Loading
Source Link
Amelio Vazquez-Reina
  • 43k
  • 81
  • 211
  • 298
Loading