anchor.diff:               return new Future.value();
              });
            } else {
  -           return getShaForEntry(entry, 'blob').then((String sha) {
  -             return entry.getMetadata().then((data) {
  -               FileStatus status = new FileStatus();
  -               status.path = entry.fullPath;
  -               status.sha = sha;
  -               status.size = data.size;
  -               updateIndexForEntry(status);
  -               filePaths.add(entry.fullPath);
  +           // don't update index for untracked files.
  +           if (_statusIdx[entry.fullPath] != null) {
  +             return getShaForEntry(entry, 'blob').then((String sha) {
  +               return entry.getMetadata().then((data) {
  +                 FileStatus status = new FileStatus();
  +                 status.path = entry.fullPath;
  +                 status.sha = sha;
  +                 status.size = data.size;
  +                 updateIndexForEntry(status);
  +                 filePaths.add(entry.fullPath);
  +               });
                });
  -           });
  +           }
            }
         }).then((_) {
           _updateDeletedFiles(filePaths);
  
positive.code:       } else {
          status.type = oldStatus.type;
        }
      } else {
        status.headSha = status.sha;
        status.type = FileStatusType.UNTRACKED;
      }
      _statusIdx[status.path] = status;
      _scheduleWriteIndex();
  
negative.code:    */
    String type;
  
    FileStatus() {
      this.type = FileStatusType.UNTRACKED;
    }
  
    static Future<FileStatus> createFromEntry(chrome.Entry entry) {
      return entry.getMetadata().then((chrome.Metadata data) {
        // TODO(grv) : check the modification time when it is available.
        return getShaForEntry(entry, 'blob').then((String sha) {
          FileStatus status = new FileStatus();
          status.path = entry.fullPath;
          status.sha = sha;
          status.size = data.size;
          status.modificationTime = data.modificationTime.millisecondsSinceEpoch;
          return status;
        });
      });
    }
  
    FileStatus.fromMap(Map m) {
      path = m['path'];
  