Attempt to dig down in to the root
object and stop on the parent of the target property.
Return the progress of the mining as an array in this structure;
[base-object, base-path, target-parent, target-property]
.
dig = (root, path, force, parseFirst = yes) ->
if path and '.' in path
path = path.split '.'
object = base = root[basePath = path.shift()]
object = base = tryParse object if parseFirst
while object and path.length > 1
object = object[path.shift()]
object = {} if not object? and force
[base, basePath, object, path.shift()]
else
[root, path, root, path]