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
Release history Release notifications | RSS feed
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 hashes)