0

noob question ... I am working on a duplicate finding program that I intend on using somewhat interchangeably between several windows and linux machines. I do realize I am re-inventing the wheel. I am seeking opinions on the "pythonic" approach of handling this situation. Seems I can get away with os and path doing a good enough job without converting file names to PurePath names.thx.

I forgot to mention that I intend on doing file name manipulations with regex. but I think I got it from here.

  • I haven't seen one better than the other, but I've generally switched to `pathlib` over `os` and `os.path` because I think it is more clear and concise (once you are used to it). I find `Path` is better than `PurePath` because it includes OS functions like open and cwd. Once you drink the kool-aide, you outta go all the way. – tdelaney Oct 04 '22 at 02:45
  • "a duplicate finding program" would need to do I/O operations, so `PurePath` won't work. `Path` would, however. The duplicate explains the difference, but isn't really a duplicate of this question. "Use `os`/`path` or \[`Path`\]" seems to be the question, which should probably be closed as "an opinion-based answer". – Mark Tolonen Oct 04 '22 at 02:46

0 Answers0