dropbox / dbxcli

A command line client for Dropbox built using the Go SDK
Other
1.05k stars 101 forks source link

Request: Add `dropbox.py` sharelink option #77

Open coatless opened 7 years ago

coatless commented 7 years ago

Could you please add to dbxcli a way to obtain the share link of a given file. e.g.

dbxcli sharelink FILE

This was previously in the headless dropbox cli given as dropbox.py. I would like to switch over from using dropbox.py to dbxcli, but my main usage case is a way for the CLI to generate sharing links for files. c.f. dropcli R package

banool commented 6 years ago

I would love to see this too. Is there a way to make this happen? If you could point me in the right direction, I might take a look at it myself.

coatless commented 6 years ago

@banool I believe the sharelink code can be found in:

https://www.dropbox.com/download?dl=packages/dropbox.py

coatless commented 6 years ago

Looks like the code for this can be found here:

https://github.com/dropbox/nautilus-dropbox/blob/48c2d695ab52f36ab1895ce42beacf458aa2700b/dropbox.in#L1022-L1045

diwakergupta commented 6 years ago

@coatless just to make sure I understand correct, you want an option in dbxcli to obtain the link you can use to share a file or a folder. Is that right?

This is actually pretty easy to do, you can even work from an existing PR: https://github.com/dropbox/dbxcli/pull/41 https://github.com/dropbox/dbxcli/pull/40

LMK if you want to take a stab. Otherwise I'll try to implement sometime in the next week.

banool commented 6 years ago

Awesome @diwakergupta, thanks for looking into this! Much easier for you than for me to learn the codebase and try it.

banool commented 6 years ago

I've put together a solution for this in #89.

biounix commented 4 years ago

To anybody interested in that option:

https://github.com/dropbox/dbxcli/issues/113#issuecomment-667919621