Stopping DMRG in Julia

Hi,

I am using ITensor Julia . Due to the time limit, I want to stop DMRG sweeps without killing it entirely. I know in C++ you can create a STOP_DMRG file in the same directory as your main file to do that. But can this be implemented in Julia?
If it can, then can you show me an example of how to do that?

Thanks

What about Observer System for DMRG · ITensors.jl?

Yes you can overload the checkdone method for your custom observer and use the Julia isfile function to check it a particular file exists.