update example to show resolving home dir dynamically