How to extract headers from a c file that contains them like this?
#include #include #include
This should work:
sed -nr 's/#include\s+[<"]([^>"]+)[>"].*/\1/p'