hy's useful code for dev