anchor.diff:     * Walks over all the files in the working tree. Returns sha of the
      * working tree.
      */
  -   Future<List<String>> walkFilesAndUpdateIndex(chrome.DirectoryEntry root,
  +   Future<List<FileStatus>> walkFilesAndUpdateIndex(chrome.DirectoryEntry root,
          bool updateSha) {
  -     List<String> filePaths = [];
  +     List<FileStatus> fileStatuses = [];
        return FileOps.listFiles(root).then((List<chrome.ChromeFileEntry> entries) {
          if (entries.isEmpty) {
  -         return filePaths;
  +         deleteIndexForEntry(root.fullPath);
  +         return fileStatuses;
          }
   
          return Future.forEach(entries, (chrome.Entry entry) {
            if (entry.name == '.git') {
  -           return filePaths;
  +           return fileStatuses;
            }
   
            if (entry.isDirectory) {
  -           return walkFilesAndUpdateIndex(entry, updateSha).then(
  -               (List<String> paths) {
  -             filePaths.addAll(paths);
  -             return filePaths;
  +           return walkFilesAndUpdateIndex(entry, updateSha).then((statuses) {
  +             fileStatuses.addAll(statuses);
              });
            } else {
              // don't update index for untracked files.
              if (_statusIdx[entry.fullPath] != null) {
  -             filePaths.add(entry.fullPath);
  +             fileStatuses.add(_statusIdx[entry.fullPath]);
                if (updateSha) {
                  return getShaForEntry(entry, 'blob').then((String sha) {
                    return entry.getMetadata().then((data) {
  
positive.code:              }
             }
           }
        }).then((_) {
           return filePaths;
         });
      });
    }
  
    /**
     * Update the index saving the information for deleted files. If the files
     * are added back, they will be restored back and not treated as untracked.
     */
    void _updateDeletedFiles(List<String> filePaths) {
      _statusIdx.forEach((String filePath, FileStatus status) {
        if (!filePaths.contains(filePath)) {
          status.deleted = true;
  
negative.code:     });
    }
  
    static FileStatus createForDirectory(chrome.Entry entry) {
      FileStatus status = new FileStatus();
      status.path = entry.fullPath;
      return status;
    }
  
    FileStatus.fromMap(Map m) {
      path = m['path'];
      headSha = m['headSha'];
  