Quickly Send Text From The Windows Command Line To The Clipboard

Grabbing information from the Windows command line could be easier, especially if all you know of is “Mark” and “Copy” in the windows’ context menu. Fortunately, there’s a great shortcut you can use, courtesy of the handy pipe (“|”) argument, that can speed up the process of securing the text your command-line programs spit out.

We’ve previously shown the old trick of capturing a command’s output using the “>” plus a filename, but this goes one step further by placing it directly on the clipboard, ready for a Ctrl+V. Amit Agarwal over at Digital Inspiration shows us that by substituting the > [filename] with | clip, you can have a command-line program redirect its content in this fashion.

Unfortunately, if you want to copy a typed-out command with arguments intact, you’ll still need to use the old “Mark / Copy” method. If anyone has a shortcut for this (without the use of third-party programs), let us know!

How to Copy the Command Output to Windows Clipboard [Digital Inspiration]


The Cheapest NBN 50 Plans

Here are the cheapest plans available for Australia’s most popular NBN speed tier.

At Lifehacker, we independently select and write about stuff we love and think you'll like too. We have affiliate and advertising partnerships, which means we may collect a share of sales or other compensation from the links on this page. BTW – prices are accurate and items in stock at the time of posting.

Comments


4 responses to “Quickly Send Text From The Windows Command Line To The Clipboard”