diff --git a/lib/git-shell-out-strategy.js b/lib/git-shell-out-strategy.js index f3fe796603..44a93bdf45 100644 --- a/lib/git-shell-out-strategy.js +++ b/lib/git-shell-out-strategy.js @@ -317,7 +317,7 @@ export default class GitShellOutStrategy { * File Status and Diffs */ async getStatusesForChangedFiles() { - const output = await this.exec(['status', '--untracked-files=all', '-z']); + const output = await this.exec(['status', '--untracked-files=all', '--ignore-submodules=dirty', '-z']); const statusMap = { 'A': 'added', diff --git a/lib/models/repository.js b/lib/models/repository.js index cce7cd8866..7757287042 100644 --- a/lib/models/repository.js +++ b/lib/models/repository.js @@ -120,7 +120,8 @@ export default class Repository { const contents = await readFile(path.join(this.getWorkingDirectoryPath(), relativePath), 'utf8'); return MERGE_MARKER_REGEX.test(contents); } catch (e) { - if (e.code === 'ENOENT') { return false; } else { throw e; } + // EISDIR implies this is a submodule + if (e.code === 'ENOENT' || e.code === 'EISDIR') { return false; } else { throw e; } } }