Skip to content
This repository has been archived by the owner on Oct 19, 2021. It is now read-only.

Commit

Permalink
docs: Update README (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
JinnyYi authored Sep 8, 2021
1 parent 2b55ce7 commit f809052
Showing 1 changed file with 28 additions and 4 deletions.
32 changes: 28 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,37 @@
# go-service-dropbox

[![Build Status](https://github.com/beyondstorage/go-service-dropbox/workflows/Unit%20Test/badge.svg?branch=master)](https://github.com/beyondstorage/go-service-dropbox/actions?query=workflow%3A%22Unit+Test%22)
[![License](https://img.shields.io/badge/license-apache%20v2-blue.svg)](https://github.com/Xuanwo/storage/blob/master/LICENSE)
[![go storage dev](https://img.shields.io/matrix/go-service-dropbox:aos.dev.svg?server_fqdn=chat.aos.dev&label=%23go-service-dropbox%3Aaos.dev&logo=matrix)](https://matrix.to/#/#go-service-dropbox:aos.dev)
[![](https://img.shields.io/matrix/beyondstorage@go-storage:matrix.org.svg?logo=matrix)](https://matrix.to/#/#beyondstorage@go-storage:matrix.org)

# go-service-dropbox

dropbox services support for [go-storage](https://github.com/beyondstorage/go-storage)
[Dropbox](https://www.dropbox.com) service support for [go-storage](https://github.com/beyondstorage/go-storage).

## Install

```go
go get github.com/beyondstorage/go-service-dropbox/v2
```

## Usage

```go
import (
"log"

_ "github.com/beyondstorage/go-service-dropbox/v2"
"github.com/beyondstorage/go-storage/v4/services"
)

func main() {
store, err := services.NewStoragerFromString("dropbox:///path/to/workdir?credential=apikey:<apikey>")
if err != nil {
log.Fatal(err)
}

// Write data from io.Reader into hello.txt
n, err := store.Write("hello.txt", r, length)
}
```

- See more examples in [go-storage-example](https://github.com/beyondstorage/go-storage-example).
- Read [more docs](https://beyondstorage.io/docs/go-storage/services/dropbox) about go-service-dropbox.

0 comments on commit f809052

Please sign in to comment.