Recently, I am studying vimscript. how can gvim automatically load files after vimscript files are modified?

  question, vim

such asa.vimThe contents are as follows

let a = 1
 Echo a "output1

I putlet a = 1Revise tolet a = 2, you need to run the command:source a.vimThe modified result will be output2.
I hopea.vimModifiedgvimCan be loaded automaticallya.vim.
How do I do this? Please give your expert advice.

You can consider triggering the event when saving with autocmd BufWritePost and automatically running the source command.