I've only ever heard this tune (called "St. Louis," written by Phillips Brooks, the organist at the Episcopal church in which Lewis Redner was a rector), but there are actually several tunes for these lyrics. One is even called "The Ploughboy's Dream," which sounds like a pretty terrific name to me.
This is far from the only hymn to be written about the events of Luke 2. It's not the only hymn to mention Bethlehem, nor is it the only one to mention the time of night or the stillness of the scene. It is, however, so far as I can tell, the only one of the fourteen hymns to mention the word "years:"
O little town of Bethlehem,
How still we see thee lie.
Above thy dark and dreamless sleep
The silent stars go by;
Yet in thy dark streets shineth
The everlasting Light.
The hopes and fears of all the years
Are met in thee tonight.
Jesus was born, depending on your calendar, anywhere between 6 B.C. and A.D. 1. Mankind had been around for at least four thousand years before that (and possibly as many as ten thousand, depending on how you define "mankind"), and all the while, they had been waiting for this moment. Prophets had long foretold the moment their Savior would come, and it's not unrealistic to suppose that for each of those four to ten thousand years, someone was looking to this very moment.
The hopes are simple enough to understand; anyone looking to Jesus' birth trusting that He would redeem them from their sins would certainly take hope from that thought. But what of the fears? Assuming they correctly understood the message, who would look to that day with fear?
Well, the Nephite people in the Book of Mormon, for one. Prophets in the Americas had also long foretold Jesus' coming, but unlike in the Old World, those believers had a death threat hanging over their heads as a result of their belief. From 3 Nephi 1:
7 And it came to pass that [those who did not believe] did make a great uproar throughout the land; and the people who believed began to be very sorrowful, lest by any means those things which had been spoken might not come to pass.
8 But behold, they did watch steadfastly for that day and that night and that day which should be as one day as if there were no night, that they might know that their faith had not been vain.
These were people of faith, but there was fear in their hearts. They had waited five years since a particularly notable prophecy in which the date of Jesus' birth was foretold, and while they trusted that those words would be fulfilled, it's easy to see why they would have been afraid. Yet despite that fear, they kept their eyes to the heavens, clutching their children a little tighter, watching for the star.
As the hymn says, "How silently the wondrous gift is giv'n." The star didn't appear in an explosion, but probably simply appeared in the sky for all to see, announcing the birth of that wondrous gift. And so too, He does not shout for our attention, but knocks softly, waiting for us to respond:
No ear may hear his coming;
But in this world of sin,
Where meek souls will receive him, still
The dear Christ enters in.