Skip to main content

filelibrary is a simple package that allows you to get and edit files or directories in a specified path.

Project description

How to use filelibrary

  1. Install filelibrary package
pip install filelibrary
  1. You're done! Now all there is to do is read the documentation.

Documentation

  1. Load Package
from filelibrary import filelibrary

fileLibrary = filelibrary("path")
  1. Get files in path
files = fileLibrary.getFileList()
print(files) # prints every files in the specified path
  1. Get directories in path
dirs = fileLibrary.getDirList()
print(dirs) # prints every directories in the specified path
  1. Print all (prints files and directories)
fileLibrary.printAll()
  1. Read file
fileLibrary.openFile("fileName.extension")
# fileLibrary.openFile("test.txt")
  1. Write file
fileLibrary.writeFile("fileName.extension", "just a text here")
# fileLibrary.writeFile("test.txt", "just a text here")
  1. Read file as JSON
fileLibrary.openFileAsJson("fileName.extension")
# fileLibrary.openFileAsJson("test.json")
  1. Write file as JSON
fileLibrary.writeFileAsJson("fileName.extension", {"data": "here"})
# fileLibrary.writeFileAsJson("test.json", {"name": "John", "age": "30"})

Congratulations! You've finished the documentation. Explore the package and create awesome projects!

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

filelibrary-0.0.2.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

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

filelibrary-0.0.2-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file filelibrary-0.0.2.tar.gz.

File metadata

  • Download URL: filelibrary-0.0.2.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.4

File hashes

Hashes for filelibrary-0.0.2.tar.gz
Algorithm Hash digest
SHA256 ec7498d4ffb01937677f67b31997ab8e2f48493595805a4a59f3f7b6a103d544
MD5 bd084540cebb5fac0f45a3c5dd5afe56
BLAKE2b-256 ac674bf48f66f36810b8fad9c57f57e7859e219ea5c7d9c6ca2995491ca2cc37

See more details on using hashes here.

File details

Details for the file filelibrary-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: filelibrary-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 4.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.4

File hashes

Hashes for filelibrary-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c915b9d1eaab457b8d12c2a12ba20605120200de14af60a5c29a1e6fe203f465
MD5 8271b67169c6f022ba14789acdc22ee9
BLAKE2b-256 885025a8e47d32ab12c25fe64f7e01cf3697cd3c74efb67261b240e6f1a83983

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