Patchwork [2,of,4] vfs: add lexists() in current api

login
register
mail settings
Submitter Chinmay Joshi
Date May 27, 2014, 6:58 p.m.
Message ID <efb2278e2384a03ba452.1401217081@ubuntu>
Download mbox | patch
Permalink /patch/4869/
State Accepted
Headers show

Comments

Chinmay Joshi - May 27, 2014, 6:58 p.m.
# HG changeset patch
# User Chinmay Joshi <c@chinmayjoshi.com>
# Date 1401211925 -19800
#      Tue May 27 23:02:05 2014 +0530
# Node ID efb2278e2384a03ba4524ad2d6c68483cf1486d5
# Parent  5dc8d26e1da18dfb8252115ac306d7f8fdd25582
vfs: add lexists() in current api

lexists is added in current API of vfs.
Matt Mackall - May 27, 2014, 7:13 p.m.
On Wed, 2014-05-28 at 00:28 +0530, Chinmay Joshi wrote:
> # HG changeset patch
> # User Chinmay Joshi <c@chinmayjoshi.com>
> # Date 1401211925 -19800
> #      Tue May 27 23:02:05 2014 +0530
> # Node ID efb2278e2384a03ba4524ad2d6c68483cf1486d5
> # Parent  5dc8d26e1da18dfb8252115ac306d7f8fdd25582
> vfs: add lexists() in current api

I've queued these first two, thanks.

Patch

diff --git a/mercurial/scmutil.py b/mercurial/scmutil.py
--- a/mercurial/scmutil.py
+++ b/mercurial/scmutil.py
@@ -178,6 +178,9 @@ 
     def islink(self, path=None):
         return os.path.islink(self.join(path))
 
+    def lexists(self, path=None):
+        return os.path.lexists(self.join(path))
+
     def lstat(self, path=None):
         return os.lstat(self.join(path))