some background, so they always say that a cause of world war one was nationalism, and pride for your country. But does that mean, that before nationalist pride was being taught in school people didn't really have their birth or adopted nation as part of their identity?
It really depends on the nation and region. I think the best way to explain this is through one example in particular but please note, this will not necessarily be the case in many nations and states.
Take the former Ottoman territories in Europe, particularly modern day Bulgaria and Macedonia. Nationalism did not become an important part of a citizens identity until the end of the 19th century. In the case of Macedonia and more remote Bulgarian communities it took even longer. (You could argue that it took until the end of WW2 in some cases).
Simply put, under Ottoman administration, religious affiliation was the most important part of ones identity by far. Your religious affiliation (whether it was Orthodox Christian, Catholic, Muslim or Jewish) dictated how much taxes you paid, what legal system you were subject to, what kind of responsibilities you were obligated to fulfill to the state and much more. It was the most important label a person had, ethnic and 'national' categories didn't exist in the form that they do today.
For centuries, the concept of a nation didn't exist (throughout the world). 'Bulgarians' were subjects of the Sultan and belonged to a specific religious community that informed their identity and culture. Bulgarians in the 17th and 18th centuries were Christians first and foremost and would label themselves as Christians, not as Bulgarians. This religious identity crossed (modern) borders and linguistic barriers to a degree which is absolutely impossible with the modern nation states.
Nationalism started to take hold in this part of the world for a multitude of reasons, but long story short, due to the rise of Western European nations, the decline of the Ottoman Empire and intellectual influence from the West, Nationalism became a powerful political tool and the 'civilized' form of political organization.
You can see similar stories in France and Germany were regional identities were slowly replaced by national identity through education, pragmatism of local elites and other reasons. I would suggest Eugene Weber's Turning Peasants into Frenchmen and also Conflicting Loyalties in the Balkans. They both deal with this issue to a degree and describe how nations were built and maintained.
I am at work so this is the best answer I can provide in the given time, I will try to make edits and I am more than happy to clarify or extrapolate on any of the points I made.
Sources: Mark Mazower The Balkans and Grandits Conflicting Loyalties in the Balkans