Skip to main content

Find files in parent directories

Project description

What is this?

A simple function for walking up a file directory until a certain file is found.

JavaScript version:

const { walkUpUntil } = require("walk_up")

let filepath = walkUpUntil("package.json")

Python version:

from walk_up import walk_up_until

filepath = walk_up_until("requirements.txt")

Ruby version:

require "walk_up"

require_relative walk_up_until("globals.rb") # <- will keep looking in parent directories for a "globals.rb" 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

walk_up-0.1.0.tar.gz (1.9 kB view details)

Uploaded Source

Built Distribution

walk_up-0.1.0-py3-none-any.whl (1.9 kB view details)

Uploaded Python 3

File details

Details for the file walk_up-0.1.0.tar.gz.

File metadata

  • Download URL: walk_up-0.1.0.tar.gz
  • Upload date:
  • Size: 1.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.6

File hashes

Hashes for walk_up-0.1.0.tar.gz
Algorithm Hash digest
SHA256 573eb8fb7b0b94fbafe86c264d0fa1abf6f49c1ced440db839d2a173395a36e5
MD5 5d7f3dddeb93194cc7f2459a6cf3cee3
BLAKE2b-256 d7eb76afa5a00fe07a741699a9b7ec7154fe8730c9d619f8ed6a5b21cf94ae24

See more details on using hashes here.

File details

Details for the file walk_up-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: walk_up-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 1.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.6

File hashes

Hashes for walk_up-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ee4434881e9f6513456ab4ecb76ba3d0fd10698884a2d63062d7d1a0d2690166
MD5 ae0fa70a8f2b7c65af5c8bd1e959b446
BLAKE2b-256 9380beda9f501026b79b160b1bf8e3fcf6f5b8fd1aaf256206f01cc90c46a18d

See more details on using hashes here.

Supported by

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