Show More
@@ -404,8 +404,6 b' def commit(ui, repo, *pats, **opts):' | |||||
404 | continue |
|
404 | continue | |
405 | if f not in files: |
|
405 | if f not in files: | |
406 | rf = repo.wjoin(f) |
|
406 | rf = repo.wjoin(f) | |
407 | if f in unknown: |
|
|||
408 | raise util.Abort(_("file %s not tracked!") % rf) |
|
|||
409 | try: |
|
407 | try: | |
410 | mode = os.lstat(rf)[stat.ST_MODE] |
|
408 | mode = os.lstat(rf)[stat.ST_MODE] | |
411 | except OSError: |
|
409 | except OSError: | |
@@ -422,6 +420,8 b' def commit(ui, repo, *pats, **opts):' | |||||
422 | elif not (stat.S_ISREG(mode) or stat.S_ISLNK(mode)): |
|
420 | elif not (stat.S_ISREG(mode) or stat.S_ISLNK(mode)): | |
423 | raise util.Abort(_("can't commit %s: " |
|
421 | raise util.Abort(_("can't commit %s: " | |
424 | "unsupported file type!") % rf) |
|
422 | "unsupported file type!") % rf) | |
|
423 | elif repo.dirstate.state(f) == '?': | |||
|
424 | raise util.Abort(_("file %s not tracked!") % rf) | |||
425 | else: |
|
425 | else: | |
426 | files = [] |
|
426 | files = [] | |
427 | try: |
|
427 | try: |
General Comments 0
You need to be logged in to leave comments.
Login now