define function for loading tags file based on filetype