jaraco/path

Maximize compatibility with `pathlib.Path`

Ouverte

#214 ouverte le 7 juil. 2023

 (7 commentaires) (0 réaction) (0 personne assignée)Python (151 forks)github user discovery
help wanted

Métriques du dépôt

Stars
 (1 125 étoiles)
Métriques de merge PR
 (Métriques PR en attente)

Description

This project does aspire to align with pathlib where possible, so it should probably do the same (and probably implement iterdir at the same time, if it's not present already).

Originally posted by @jaraco in https://github.com/jaraco/path/issues/212#issuecomment-1623882608

Here some other methods that are worth considering:

set(vars(pathlib.Path)) - set(vars(path.Path)) 
Out[9]: 
{'__slots__',
 '_make_child_relpath',
 '_scandir',
 'absolute',
 'cwd',
 'group',
 'hardlink_to',
 'home',
 'is_block_device',
 'is_char_device',
 'is_dir',
 'is_fifo',
 'is_file',
 'is_mount',
 'is_socket',
 'is_symlink',
 'iterdir',
 'lchmod',
 'link_to',
 'replace',
 'resolve',
 'rglob',
 'symlink_to'}
  • absolute
  • cwd
  • group
  • hardlink_to
  • home
  • is_block_device
  • is_char_device
  • is_dir
  • is_fifo
  • is_file
  • is_mount
  • is_socket
  • is_symlink
  • iterdir
  • lchmod
  • link_to
  • owner
  • replace
  • resolve
  • rglob
  • suffix
  • symlink_to
  • with_stem
  • with_name

Guide contributeur