Science Score: 36.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
✓DOI references
Found 3 DOI reference(s) in README -
✓Academic publication links
Links to: zenodo.org -
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (12.6%) to scientific vocabulary
Keywords
Keywords from Contributors
Repository
Dropbox Interface from R
Basic Info
- Host: GitHub
- Owner: karthik
- License: other
- Language: R
- Default Branch: master
- Size: 1.21 MB
Statistics
- Stars: 254
- Watchers: 15
- Forks: 60
- Open Issues: 72
- Releases: 3
Topics
Metadata Files
README.md
rdrop2 - Dropbox interface from R 
🚨🚨🚨 Call for maintainers 🚨🚨🚨
The package is currently not maintained and up for adoption. If you are interested in taking over as maintainer, please send an email to karthik.ram@gmail.com.
If we can't find another maintainer before something breaks on CRAN, the package will be archived. 🙏 🚨🚨🚨
Maintainers: Karthik Ram (@karthik) and Clayton Yochum (@ClaytonJY)
This package provides programmatic access to Dropbox from R. The functions in this package provide access to a full suite of file operations, including dir/copy/move/delete operations, account information and the ability to upload and download files from any Dropbox account.
Installation
```
Current CRAN version (0.8.1)
install.packages('rdrop2')
or the development version (0.8.1.9999)
devtools::install_github("karthik/rdrop2") ```
Authentication
```r library(rdrop2) drop_auth()
This will launch your browser and request access to your Dropbox account. You will be prompted to log in if you aren't already logged in.
Once completed, close your browser window and return to R to complete authentication.
The credentials are automatically cached (you can prevent this) for future use.
If you wish to save the tokens, for local/remote use
token <- drop_auth() saveRDS(token, file = "token.rds")
Then in any drop_* function, pass `dtoken = token
Tokens are valid until revoked.
```
Retrieve Dropbox account information
```r library(dplyr) drop_acc() %>% data.frame()
Returns the following fields
[1] "accountid" "name.givenname"
[3] "name.surname" "name.familiar_name"
[5] "name.displayname" "name.abbreviatedname"
[7] "email" "email_verified"
[9] "disabled" "country"
[11] "locale" "referral_link"
[13] "is_paired" ".tag"
```
Dropbox directory listing
```r write.csv(mtcars, "mtcars.csv") dropupload("mtcars.csv") dropdir()
If your account is not empty, it returns the following fields
[1] ".tag" "name" "path_lower"
[4] "pathdisplay" "id" "clientmodified"
[7] "server_modified" "rev" "size"
[10] "content_hash"
or specify a path
drop_dir('public/gifs') ```
|.tag |name |pathlower |pathdisplay |id |clientmodified |servermodified |rev | size|content_hash | |:----|:----------|:-----------|:------------|:-------------------------|:--------------------|:--------------------|:------------|----:|:----------------------------------------------------------------| |file |mtcars.csv |/mtcars.csv |/mtcars.csv |id:b-ac9BwzYUAAAAAAAAAxFQ |2017-09-27T16:21:56Z |2017-09-27T16:21:57Z |691634207848 | 1783|8c00dcec5f3e6bf58a42dcf354f0d5199a43567e88a9d80291bd2b85f53a54a5 |
Filter directory listing by object type (file/folder)
r
drop_dir() %>%
filter(.tag == "folder")
Create folders on Dropbox
```r dropcreate('droptest')
or provide the full path where it needs to be created
dropcreate('public/droptest') ```
Upload a file into Dropbox
csv files
```r
write.csv(mtcars, 'mtcars.csv')
drop_upload('mtcars.csv')
or upload to a specific folder
dropupload('mtcars.csv', path = "droptest") ```
You can also do this for any other file type and large files are supported regardless of your memory.
Download a file
```r drop_download('mtcars.csv')
or add path if file is not in root
dropdownload("testfolder/mtcars.csv") ```
Delete a file
r
drop_delete('mtcars.csv')
Move files
r
drop_create("new_folder")
drop_move("mtcars.csv", "new_folder/mtcars.csv")
Copy files
r
drop_create("new_folder2")
drop_copy("new_folder/mtcars.csv", "new_folder2/mtcars.csv")
Search and download files
I frequently use a duck season rabbit season gif. This is how I could search and download from my public Dropbox account.
```r x <- dropsearch("rabbit") dropdownload(x$matches[[1]]$metadata$pathlower, localpath = '~/Desktop/bugs.gif')
Downloaded /public/gifs/duck_rabbit.gif to ~/Desktop/bugs.gif: 329.2 Kb on disk
```
Read csv files directly from Dropbox
```r write.csv(iris, file = "iris.csv") drop_upload("iris.csv")
Now let's read this back into an R session
Note that there is a quiet download happening to your temp dir
newiris <- dropread_csv("iris.csv") ```
Accessing Dropbox on Shiny and remote servers
If you expect to access a Dropbox account via Shiny or on a remote cluster, EC2, Digital Ocean etc, you can leave the cached oauth file in the same directory, or pass the token explicitly to drop_auth. You can also save the output of drop_auth into an R object, sink that to disk, and pass that as a token. If using on Travis or similar, you should consider encrypting the oauth cache file to prevent unauthorized access to your Dropbox account. If you have multiple tokens and accounts, it is also possible to override the environment token and explicitly pass a specific token for each drop_ function.
```r token <- drop_auth() saveRDS(token, "droptoken.rds")
Upload droptoken to your server
******** WARNING ********
Losing this file will give anyone
complete control of your Dropbox account
You can then revoke the rdrop2 app from your
dropbox account and start over.
******** WARNING ********
read it back with readRDS
token <- readRDS("droptoken.rds")
Then pass the token to each drop_ function
drop_acc(dtoken = token) ```
Meta
Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.
For bug reports and known problems, please look over the issues before filing a new report.
Owner
- Name: Karthik Ram
- Login: karthik
- Kind: user
- Location: Berkeley, CA
- Company: @ucberkeley
- Website: https://ram.berkeley.edu
- Twitter: _inundata
- Repositories: 219
- Profile: https://github.com/karthik
Research associate professor at UC Berkeley
GitHub Events
Total
- Watch event: 3
- Fork event: 1
Last Year
- Watch event: 3
- Fork event: 1
Committers
Last synced: 9 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Karthik Ram | k****m@g****m | 360 |
| Clayton Yochum | c****y@g****m | 37 |
| Caleb Scheidel | c****b@m****m | 4 |
| Veliko Minkov | v****v@s****m | 3 |
| Ross Ireland | r****d@g****m | 1 |
| Rich FitzJohn | r****n@g****m | 1 |
| ImgBotApp | I****p@g****m | 1 |
| Felipe Campelo | f****o@g****m | 1 |
| Dean Attali | d****i@g****m | 1 |
| Anders Riis | a****r@m****k | 1 |
| ajzz | a****l@s****m | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 9 months ago
All Time
- Total issues: 78
- Total pull requests: 27
- Average time to close issues: 2 months
- Average time to close pull requests: 5 months
- Total issue authors: 62
- Total pull request authors: 15
- Average comments per issue: 2.79
- Average comments per pull request: 1.3
- Merged pull requests: 14
- Bot issues: 0
- Bot pull requests: 1
Past Year
- Issues: 0
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 0
- Pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- karthik (6)
- ClaytonJY (4)
- cfitzge1 (2)
- Fablepongiste (2)
- SimonHeuberger (2)
- phillc73 (2)
- navenachaitoo (2)
- nicocriscuolo (2)
- scottyaz (2)
- HenrikBengtsson (2)
- JoseBartolomei (1)
- praneetheranti (1)
- mkirzon (1)
- BrookeGibbons (1)
- DataEconomistDK (1)
Pull Request Authors
- karthik (9)
- ClaytonJY (5)
- ellisvalentiner (2)
- fcampelo (2)
- dholstius (1)
- LiNk-NY (1)
- lewishounkpevi (1)
- jcarbaut (1)
- tadhg-moore (1)
- yogat3ch (1)
- aleDsz (1)
- imgbot[bot] (1)
- richfitz (1)
- jcolomb (1)
- 5vxssbdahves (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- cran 3,754 last-month
- Total docker downloads: 43,317
- Total dependent packages: 2
- Total dependent repositories: 11
- Total versions: 5
- Total maintainers: 1
cran.r-project.org: rdrop2
Programmatic Interface to the 'Dropbox' API
- Documentation: http://cran.r-project.org/web/packages/rdrop2/rdrop2.pdf
- License: MIT + file LICENSE
- Status: removed
-
Latest release: 0.8.2.1
published over 5 years ago
Rankings
Maintainers (1)
Dependencies
- R >= 3.1.1 depends
- assertive * imports
- digest * imports
- dplyr * imports
- httr * imports
- jsonlite * imports
- magrittr * imports
- purrr * imports
- testthat * suggests
- uuid * suggests