Support resources only/except options with nested contexts. Close #42.