Support importing tags

Merging from master. Per #347.