Skip to main content

os.walk with maxdepth option

Project description

shortwalk

os.walk that can go no deeper than you want it to, and can jump over obstacles.

Install

pip install shortwalk

Use

from shortwalk import walk

for root, dirs, files in walk(path, maxdepth=2, skip=['.git', '*.egg-info']):
    for file in files:
        do_stuff_with(file)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

shortwalk-0.0.3.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

shortwalk-0.0.3-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file shortwalk-0.0.3.tar.gz.

File metadata

  • Download URL: shortwalk-0.0.3.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.1

File hashes

Hashes for shortwalk-0.0.3.tar.gz
Algorithm Hash digest
SHA256 92a3a2a2f720869222836ff5bc26ec63a6fb39a9fa67ce3922acf6f24bd54c33
MD5 ca101b3722b9437583fa754b971e781e
BLAKE2b-256 6b212e9352373c320e40615d98e6590bd509ba07712275bd59258b26055338c6

See more details on using hashes here.

File details

Details for the file shortwalk-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: shortwalk-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.1

File hashes

Hashes for shortwalk-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 85d0594202121c36976f6e7fbc77e6bd9d26159aac36c73f1c35c0b6a53c7465
MD5 52c9264d17c6e593361d09c4458a47e4
BLAKE2b-256 0fa1e0f151b2d1e57068040dec12f2113081267252f1558862489575e1bc1244

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page