justindujardin / pathy

simple, flexible, offline capable, cloud storage with a Python path-like interface
Apache License 2.0
171 stars 23 forks source link

Feature/s3 #54

Closed justindujardin closed 3 years ago

justindujardin commented 3 years ago

Add support for S3 bucket access. To use, install the s3 package extras:

pip install pathy[s3]

Then you can use s3 paths similarly to gs ones:

from pathy import Pathy

a = Pathy("s3://pathy-tests-bucket/myfile.txt")
a.touch()
a.write_text("Hello World!")
assert a.read_text() == "Hello World!"

If you install the gcs extras too, you can do neat things like copy files from one service to another:

pip install "pathy[s3,gcs]"
pathy cp gs://bucket/copy.zip s3://bucket/file.zip

Changes

codecov[bot] commented 3 years ago

Codecov Report

Merging #54 (6f139ce) into master (ecbc5fa) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##            master       #54    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files            4         5     +1     
  Lines          884      1027   +143     
==========================================
+ Hits           884      1027   +143     
Impacted Files Coverage Δ
pathy/__init__.py 100.00% <100.00%> (ø)
pathy/s3.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update ecbc5fa...6f139ce. Read the comment docs.

github-actions[bot] commented 3 years ago

:tada: This PR is included in version 0.5.1 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: