At the DSpace repositories of Massey University and University of Waikato in New Zealand there are buttons to share the link to a document in the repository with Twitter, Facebook and other social media.
Also have both sites a Window with Twitter tweets.
I hope someone of you wants to explain how both functionalities are added to the DSpace Mirage 2 theme.
terrywb's answer covers the share button aspect - that is exactly the service used at the University of Waikato's repository that Peter linked to. We add the JavaScript in navigation.xsl not page-structure.xsl, and we also add
<div class="addthis_sharing_toolbox list-group" style="min-height:37.5px"></div>
just after the opening tag for the #ds-options
div, in line with the AddThis embedding instructions.
As to the tweets on the home page, refer to the Twitter embedded timeline instructions. I believe we add a placeholder div via news-xmlui.xml that then triggers a template in theme.xsl that pulls in the JavaScript and generates the required a
element - example below is from the Twitter documentation.
<a class="twitter-timeline"
href="https://twitter.com/TwitterDev"
data-width="300"
data-height="300">
Tweets by @TwitterDev
</a>