18
Python's pathlib module (www.pythonmorsels.com)
you are viewing a single comment's thread
view the rest of the comments
[-] eager_eagle@lemmy.world 1 points 4 days ago

Nice, mypath.open() is a more semantic alternative to open(my path)

[-] joyjoy@lemm.ee 1 points 4 days ago

Don't forget about the helper functions mypath.read_text() and mypath.write_text(content)

[-] eager_eagle@lemmy.world 1 points 4 days ago

that's already in the cheatsheet

[-] ulterno@programming.dev -1 points 3 days ago

Today I realised, we all prefer semantics matching oriental language semantics.
English: Open my path.
Same sentence in Hindi semantics would be: My path open.

this post was submitted on 18 Nov 2024
18 points (100.0% liked)

Python

6394 readers
12 users here now

Welcome to the Python community on the programming.dev Lemmy instance!

📅 Events

PastNovember 2023

October 2023

July 2023

August 2023

September 2023

🐍 Python project:
💓 Python Community:
✨ Python Ecosystem:
🌌 Fediverse
Communities
Projects
Feeds

founded 1 year ago
MODERATORS