We know that our sun is a fairly common star. In fact, the fanciest thing about our sun is probably the fact that the 3rd planet (Earth) in its solar system has life!
In this video, astronomers talk about how they can use the line spectra from stars to classify them into different categories.