Enable copying of code block without leading '$' for command-line examples #84
                  
                    
                      ppiegaze
                    
                  
                
                  started this conversation in
                Feature Requests
              
            Replies: 0 comments
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
-
What's your feature/idea?
When using a code block to display a CLI command I often prefix the command with the prompt '$' or '>' to indicate that the text is to be entered at the command line. However, when the reader copies the text using the 'copy' button the prompt is copied along with command-line text. Pasting it to the terminal then results in an extraneous leading character.
It would be great if there was an option similar to the existing option to add line numbers that added a command prompt in front of each line, with the author filling in only the actual command itself and this text being the only thing that is copied on clicking the copy button.
What's your desired outcome?
This would result in a slightly smoother experience for the reader/user of my docs. Every little bit counts!
What's the impact of this for you?
Anything else?
No response
Beta Was this translation helpful? Give feedback.
All reactions