@@ -553,12 +553,6 @@ def walk(self, top_down=True, on_error=None, follow_symlinks=False):
553553 yield path , dirnames , filenames
554554 paths += [path .joinpath (d ) for d in reversed (dirnames )]
555555
556- def expanduser (self ):
557- """ Return a new path with expanded ~ and ~user constructs
558- (as returned by os.path.expanduser)
559- """
560- raise UnsupportedOperation (self ._unsupported_msg ('expanduser()' ))
561-
562556 def readlink (self ):
563557 """
564558 Return the path to which the symbolic link points.
@@ -579,20 +573,6 @@ def _symlink_to_target_of(self, link):
579573 """
580574 self .symlink_to (link .readlink ())
581575
582- def hardlink_to (self , target ):
583- """
584- Make this path a hard link pointing to the same file as *target*.
585-
586- Note the order of arguments (self, target) is the reverse of os.link's.
587- """
588- raise UnsupportedOperation (self ._unsupported_msg ('hardlink_to()' ))
589-
590- def touch (self , mode = 0o666 , exist_ok = True ):
591- """
592- Create this file with the given access mode, if it doesn't exist.
593- """
594- raise UnsupportedOperation (self ._unsupported_msg ('touch()' ))
595-
596576 def mkdir (self , mode = 0o777 , parents = False , exist_ok = False ):
597577 """
598578 Create a new directory at this given path.
@@ -711,37 +691,3 @@ def move_into(self, target_dir):
711691 else :
712692 target = self .with_segments (target_dir , name )
713693 return self .move (target )
714-
715- def chmod (self , mode , * , follow_symlinks = True ):
716- """
717- Change the permissions of the path, like os.chmod().
718- """
719- raise UnsupportedOperation (self ._unsupported_msg ('chmod()' ))
720-
721- def lchmod (self , mode ):
722- """
723- Like chmod(), except if the path points to a symlink, the symlink's
724- permissions are changed, rather than its target's.
725- """
726- self .chmod (mode , follow_symlinks = False )
727-
728- def owner (self , * , follow_symlinks = True ):
729- """
730- Return the login name of the file owner.
731- """
732- raise UnsupportedOperation (self ._unsupported_msg ('owner()' ))
733-
734- def group (self , * , follow_symlinks = True ):
735- """
736- Return the group name of the file gid.
737- """
738- raise UnsupportedOperation (self ._unsupported_msg ('group()' ))
739-
740- @classmethod
741- def from_uri (cls , uri ):
742- """Return a new path from the given 'file' URI."""
743- raise UnsupportedOperation (cls ._unsupported_msg ('from_uri()' ))
744-
745- def as_uri (self ):
746- """Return the path as a URI."""
747- raise UnsupportedOperation (self ._unsupported_msg ('as_uri()' ))
0 commit comments