Add a shell function in object.