Skip to main content

A file lister on steroids

Project description

listevery

A Python package which can list contents of directories and subdirectories, without a depth limit!

(yes, I know there's os.walk i don't care)

Usage

Running the program in the Python shell is a little strange. You can only get the files and directories of the pip package location. Even though it is a little pointless, run python -m listevery [folder] and you will get a structure similar to this.

[folder1] [file1.txt, file2.py]
[] [thing.mp4]

I'll explain. The first list (folder1) shows the folders in the directory, and the second list (file1.txt, file2.py) shows the files. Then it will look in the first directory of the first list and show any files or folders availible. It stops when a folder could not be found.

If you want to run this in a Python script, check out the import.py.test usage script in the downloads. This script is a guide to help you run the package by import.

Luckily, running listevery in a Python script is so much better. For starters, you can actually get the contents of directories besides the pip package, and the result is given in a lovely and usable list. Ha take that, tree command! Speaking of lists, listevery can index specific things for you.

Here's a few different usages:

Get all the files and directories:

from listeveryu import listevery
listevery('.', '*')

Get specific items:

from listevery import listevery
listevery('.', int)

Not too hard right? You may get whitespaces and trailing, but you can probably find a way around that. (ಠuಠ)

New updates

  - Fixed up the Python file to run the module. Gives a less buggy and a usable result!

Compatibility

Will work ✔:
  - Windows 7 or above
  - GNU/Linux
  - MacOS

Does not work properly ⚠:
  - Replit
  - Heroku

Will not work ❌:
  - Online compilers (e.g: TutorialsPoint, OnlineGDB)

Have issues? Post them here.

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

listevery-0.1.61.tar.gz (3.0 kB view details)

Uploaded Source

File details

Details for the file listevery-0.1.61.tar.gz.

File metadata

  • Download URL: listevery-0.1.61.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.10.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.8.0 tqdm/4.60.0 CPython/3.8.9

File hashes

Hashes for listevery-0.1.61.tar.gz
Algorithm Hash digest
SHA256 8bd27a46af0064607ca473a922c24cfe78c079b0b7265fd13b4ad8fec2e79102
MD5 d96afb1b1c25ec99504589bb031a7c9c
BLAKE2b-256 8df6586aed2bfe72fb0954808726018d8981cfb48187e74ef36dcebadc514741

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