I\'m developing android apps in eclipse and how can I get logcat messages to my clipboard?
Ctrl + C works but you need to make sure to make sure you click on the first line of any output that is split into multiple lines.
For those of you working with Eclipse on a Macintosh, here's a work-around:
Yup, I know; it's a pain in the ass, but it works.
Also notable is that as of at least ADT plugin version 21 there is a TID column displayed in Eclipse's logcat viewer when you have display settings on maximum verbosity, but the thread id will not be preserved if you copy and paste the content of this view. Instead you'll see something like [debug level] [timestamp] [invocation] (PID)... but no thread id. I don't know if there is an easier way to grab the TID data directly from eclipse, but it can be done using a remote adb shell as follows:
Execute the following from your PC's command line: adb -s [your device's serial number] shell "logcat -v threadtime" > [your_output_file]
your session will appear to hang, but in actuality the device's logcat output, exactly as shown in eclipse's logcat view including the TID, is being written in real time to your output file. When you want to view the content, exit the logcat dump process with ctrl+c and open the file on your PC. Other options for logcat filtering etc. can be found [here].1
put cursor in the logcat window. ctrl-a select all ctrl-c copy what's selected (which will be all) run vi then paste.
You can click on the output line in LogCat and click ctrl+c like normal then a normal paste into whatever you want. You can use shift and click to select multiple lines.
From a command line:
adb logcat > log.txt