Compare commits

..

4 commits

Author SHA1 Message Date
David Wakelin
6b0f8f5e03 Added deprecation notice 2023-12-15 11:07:08 +00:00
David Wakelin
8ac092ea96 Version bump from bugfix 2023-12-15 11:06:58 +00:00
Aleksandar Kolakov
4f4b6148d2 Fixed hardcoded region in Spaces constructor 2023-12-15 10:30:35 +00:00
David Wakelin
6bc100cf90 Added move example to readme 2023-02-01 11:19:59 +00:00
3 changed files with 8 additions and 4 deletions

View file

@ -1,6 +1,7 @@
![Spaces-API](https://imgur.com/NYNsQyl.png "Devang Srivastava's Spaces-API") # This library is deprecated
We recommend using the [official SDK](https://github.com/DigitalOceanPHP/Client) or the [Laravel package](https://github.com/GrahamCampbell/Laravel-DigitalOcean)
PHP library for accessing Digital Ocean spaces All issues will be closed and new PRs will not be accepted
## Installation ## Installation
Install via composer Install via composer
@ -32,6 +33,9 @@ $file2url = $file2->getSignedURL("2 hours");
// Make a copy // Make a copy
$file3 = $file2->copy('remote-file-3.txt'); $file3 = $file2->copy('remote-file-3.txt');
// Move or rename a file
$file2->move('new-filename.txt')
// Make a file public and get the URL // Make a file public and get the URL
$file3->makePublic(); $file3->makePublic();
$file3url = $file3->getURL(); $file3url = $file3->getURL();

View file

@ -36,7 +36,7 @@ class Spaces
{ {
$this->s3 = new S3Client([ $this->s3 = new S3Client([
"version" => "latest", "version" => "latest",
"region" => "us-east-1", "region" => $region,
"endpoint" => "https://$region.$host", "endpoint" => "https://$region.$host",
"credentials" => ["key" => $accessKey, "secret" => $secretKey], "credentials" => ["key" => $accessKey, "secret" => $secretKey],
"ua_append" => "SociallyDev-Spaces-API/2", "ua_append" => "SociallyDev-Spaces-API/2",

View file

@ -1,7 +1,7 @@
{ {
"name": "sociallydev/spaces-api", "name": "sociallydev/spaces-api",
"description": "Library for accessing Digital Ocean spaces", "description": "Library for accessing Digital Ocean spaces",
"version":"3.6.0", "version":"3.6.1",
"type": "library", "type": "library",
"license": "MIT", "license": "MIT",
"authors": [ "authors": [