Skip to main content

Just a random package to deal with CSV files

Project description

ManagerCSV

Just a random package to deal with csv file.

Installation

Just use pip

pip install ManagerCSV

Usage

For some reason, to import the lib you need to precise .index after the lib name

Read a file:

from ManagerCSV.index import CSV_manager

csv_file = CSV_manager("/path/to/your/file")

for values in csv_file.read_csv():
  print(values)

Since the read_csv method, return a generator of lists, you must iterate over it to read the file content.

Write a file:

from ManagerCSV.index import CSV_manager

csv_file = CSV_manager("/path/to/your/file")

datas: list[list[any]] = [ [ "Name", "First name", "Birth Year" ], [ "Turing", "Alan", 1912 ], [ "Lovelace", "Ada", 1815 ], [ "Shanon", "Claude", 1916 ], [ "Truong", "André", 1936 ] ]

csv_file.write_csv(datas)

To write into a file you have to provide a 2-dimensional array, Each Subarray in the main array represents columns and the data present in them, will be displayed on rows. In this case, the csv file, will looks like this

view of a csv 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

ManagerCSV-1.0.1.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

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

ManagerCSV-1.0.1-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file ManagerCSV-1.0.1.tar.gz.

File metadata

  • Download URL: ManagerCSV-1.0.1.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.12

File hashes

Hashes for ManagerCSV-1.0.1.tar.gz
Algorithm Hash digest
SHA256 4656d1ece13fa3c42a40e85881d41c817fcc705079506e7ce8c4352ab1ec9f49
MD5 83bb4be9a7dc80268eccc7ba46ff3510
BLAKE2b-256 427aad79f4073210fefdc6240a719efcb9afcf6480abd5211582b4706741c817

See more details on using hashes here.

File details

Details for the file ManagerCSV-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: ManagerCSV-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.12

File hashes

Hashes for ManagerCSV-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f79b6b05906833fb0f29238a9ce8040c82d7a1c313bea0e0902a994be3914be7
MD5 3586123647a00034124338dc4b0845e9
BLAKE2b-256 8282dfd33aa7ab709c35268c006560f9eb442bc34be481c8c8075f345eb6d76c

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