refactors update_ctags script