jangler / droxi Goto Github PK
View Code? Open in Web Editor NEWDefunct ftp-like command-line Dropbox interface in Ruby
License: MIT License
Defunct ftp-like command-line Dropbox interface in Ruby
License: MIT License
I'm making an ebuild for droxi and I need an exact dependencies. As I see, it is a dropbox-sdk-*.gem at least? What ruby versions?
When things go wrong I'm often asked to prove that and when a file was transferred. lftp solves this with it's robust logging. Here's some log lines from lftp that show when, from, to, and size.
2015-05-27 23:55:12 /home/droxi/INPUT125.txt -> sftp://[email protected]/INPUT125.txt 0-146336 98.2 KiB/s
2015-05-28 00:03:16 sftp://[email protected]/DATA63.txt -> /home/droxi/DATA63.txt 0-701 34.8 KiB/s
2015-05-29 18:23:08 sftp://[email protected]/DATA64.txt -> /home/droxi/DATA64.txt 0-1922 99.0 KiB/s
date: was the file sent in a timely fashion?
name/size: which file is it?
from: received or sent?
to: did it go to the right place?
size: was the data complete?
speed: is there a network problem?
errors: what caused the failure? (lftp does not log errors, but it should)
With version v0.5.0 running just droxi
does not start interactive mode anymore. CLI commands also stopped working.
However, when invoking droxi
with --help
or --version
argument, following error occurs:
$ droxi --version
droxi v0.5.0
/home/user/.gem/ruby/2.4.0/gems/droxi-0.5.0/lib/droxi.rb:54:in `ensure in run': undefined method `exit_status' for nil:NilClass (NoMethodError)
from /home/user/.gem/ruby/2.4.0/gems/droxi-0.5.0/lib/droxi.rb:54:in `run'
from /home/user/.gem/ruby/2.4.0/gems/droxi-0.5.0/bin/droxi:3:in `<top (required)>'
from /home/user/.gem/ruby/2.4.0/bin/droxi:23:in `load'
from /home/user/.gem/ruby/2.4.0/bin/droxi:23:in `<main>'
I love the idea of using CLI and API to selectively sync files with FTP-alike commands, so I'd love to help to fix the issue. However I'm not a Ruby programmer at all (but I still may try to do something when guided!).
Hi there,
Once again thanks for this great project I've been using to upload my server backups to dropbox. Lately I have noticed something though, as the upload fails sometimes. After checking it out I find droxi process keeps hanging for days. Maybe this is a sign that your upload code does not handle timeout and retry as resilient as it should. Can you do something about this?
If you need any log or additional info, please tell me.
Best regards,
"On June 28, 2017, API v1 will be turned off." —Dropbox
There's a migration guide, but it specifically mentions that there's no info about Ruby migration yet. I expect I have to wait until the Ruby Dropbox SDK is updated to deal with v2.
On behalf of Olivier--
Local file globbing for the 'put' command doesn't appear to be implemented, and it really should be. Without it, batch uploading is unreasonably tedious.
Hi there,
Thanks for this great tool. I've been using it to backup my server data to dropbox and it works great. There's one small feature quest I have though. Can you add a final parameter in the droxi put command so I can put directly to a subdirectory on dropbox? e.g. calling from linux shell like this:
droxi put backupFiles subdirOnDropboxPath
I need this because I run droxi command from inside a systemd scheduled shell script.
Thanks and best regards,
Ngoc-Thuan Tran
The Dropbox API operates in a case-insensitive manner in some cases and in a case-sensitive manner in other cases, which can currently cause some weird edge-case problems for droxi.
For example, if you have a Dropbox folder at "/FOLDER" and you move/rename it to "/folder" (using the web interface, for example), the path metadata for all the files in that folder won't be updated--a file at "/FOLDER/file.ext" will still have that path. If you do ls /folder
, you'll get nothing, and if you do ls /FOLDER
, you'll get "ls: /FOLDER: no such file or directory", but if you do ls /FOLDER/file.ext
you'll get "/FOLDER/file.ext".
I can't think of a reliable way to fix this on droxi's side, so for now I'll open an issue on the Dropbox dev forum.
I'm trying to put
a large file (around 500Mb), and it returns an error after a couple of minutes:
Dropbox Server Error: body=
<html>
<head><title>Dropbox - 4xx</title>
<link href="https://www.dropbox.com/static/css/main.css" rel="stylesheet" type="text/css">
<link rel="shortcut icon" href="/static/images/favicon.ico"/>
</head>
<body style="background-color:#fff">
<br/><br/>
<div align="center">
<table><tr><td width="600px">
<center><img id="errorimage" src="/static/images/psychobox.png"/></center>
<div id="errorbox">
<h1>Error (4xx)</h1>We can't find the page you're looking for. Check out our <a href="https://www.dropbox.com/help">Help Center</a> and <a href="https://forums.dropbox.com">forums</a> for help, or head back to <a href="https://www.dropbox.com/home">home</a>.
</div>
</td></tr></table>
</div>
<script type="text/javascript" src="/static/javascript/external/prototype.js"></script>
<script>
// (a bunch of JavaScript)
</script>
</body>
</html>
The file uploads without error using the web interface in Chrome. Anything else I can do to help debug this?
After the new code update droxi does not work for me:
$ touch newfile
$ droxi put -f -O /Public/myfolder newfile
put: /Public/myfolder: no such file or directory
./newfile -> /newfileIt store the newfile in the root directory.
The myfolder actually exists in /Public.
Here, the -f -O
is getting interpreted as the -f FILE
option of droxi rather than the intended -f
and -O
options of put
. The option parser should stop grabbing droxi-level options as soon as it reads an argument that isn't one.
Please add the man page to your AUR package. "droxi --help" says there will be a man page but there isn't one.
Thanks for this useful tool that allows to use Dropbox without copying whole folder.
One of very useful applications for it could be using Dropbox as git repository storage. git allows to use pluggable remote helpers. It would be great to have "droxi::" protocol support that allows git to use droxi transparently with minimum efforts.
See man gitremote-helpers
that describes list of commands that remotehelper should support.
cormorant[]$ ruby --version]$ droxi
ruby 2.1.5p273 (2014-11-13 revision 48405) [x86_64-linux]
cormorant[
Logged in as Ildar Amankulov ([email protected])
droxi [email protected]:/>
cormorant[~]$
cormorant[]$ ruby --version]$ droxi
ruby 2.2.0p0 (2014-12-25 revision 49005) [x86_64-linux]
cormorant[
/usr/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in require': cannot load such file -- dropbox_sdk (LoadError) from /usr/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in
require'
from /usr/bin/droxi:1209:in `
cormorant[~]$ ruby --version
ruby 2.1.5p273 (2014-11-13 revision 48405) [x86_64-linux]
cormorant[~]$ droxi
Logged in as Ildar Amankulov ([email protected])
droxi [email protected]:/>
cormorant[~]$ downgrade ruby
Available packages:
1) ruby-2.2.0-1-x86_64.pkg.tar.xz (local)
2) ruby-2.1.5-1-x86_64.pkg.tar.xz (local)
3) ruby-2.1.5-1-x86_64.pkg.tar.xz (remote)
4) ruby-2.1.4-1-x86_64.pkg.tar.xz (remote)
5) ruby-2.1.3-2-x86_64.pkg.tar.xz (remote)
6) ruby-2.1.2-1-x86_64.pkg.tar.xz (remote)
7) ruby-2.1.1-2-x86_64.pkg.tar.xz (remote)
8) ruby-2.1.1-1-x86_64.pkg.tar.xz (remote)
9) ruby-2.1.0-2-x86_64.pkg.tar.xz (remote)
10) ruby-2.0.0_p353-1-x86_64.pkg.tar.xz (remote)
select a package by number: 1
loading packages...
resolving dependencies...
looking for conflicting packages...
Packages (1) ruby-2.2.0-1
Total Installed Size: 20.23 MiB
Net Upgrade Size: 1.93 MiB
:: Proceed with installation? [Y/n]
(1/1) checking keys in keyring [####################################################################] 100%
(1/1) checking package integrity [####################################################################] 100%
(1/1) loading package files [####################################################################] 100%
(1/1) checking for file conflicts [####################################################################] 100%
(1/1) checking available disk space [####################################################################] 100%
(1/1) upgrading ruby [####################################################################] 100%
New optional dependencies for ruby
tk: for Ruby/TK
cormorant[~]$ ruby --version
ruby 2.2.0p0 (2014-12-25 revision 49005) [x86_64-linux]
cormorant[~]$ droxi
/usr/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- dropbox_sdk (LoadError)
from /usr/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
from /usr/bin/droxi:1209:in `<main>'
cormorant[~]$ downgrade ruby
Available packages:
1) ruby-2.2.0-1-x86_64.pkg.tar.xz (local)
2) ruby-2.1.5-1-x86_64.pkg.tar.xz (local)
3) ruby-2.1.5-1-x86_64.pkg.tar.xz (remote)
4) ruby-2.1.4-1-x86_64.pkg.tar.xz (remote)
5) ruby-2.1.3-2-x86_64.pkg.tar.xz (remote)
6) ruby-2.1.2-1-x86_64.pkg.tar.xz (remote)
7) ruby-2.1.1-2-x86_64.pkg.tar.xz (remote)
8) ruby-2.1.1-1-x86_64.pkg.tar.xz (remote)
9) ruby-2.1.0-2-x86_64.pkg.tar.xz (remote)
10) ruby-2.0.0_p353-1-x86_64.pkg.tar.xz (remote)
select a package by number: 2
loading packages...
warning: downgrading package ruby (2.2.0-1 => 2.1.5-1)
resolving dependencies...
looking for conflicting packages...
Packages (1) ruby-2.1.5-1
Total Installed Size: 18.30 MiB
Net Upgrade Size: -1.93 MiB
:: Proceed with installation? [Y/n]
(1/1) checking keys in keyring [####################################################################] 100%
(1/1) checking package integrity [####################################################################] 100%
(1/1) loading package files [####################################################################] 100%
(1/1) checking for file conflicts [####################################################################] 100%
(1/1) checking available disk space [####################################################################] 100%
(1/1) downgrading ruby [####################################################################] 100%
cormorant[~]$ ruby --version
ruby 2.1.5p273 (2014-11-13 revision 48405) [x86_64-linux]
cormorant[~]$ droxi
Logged in as Ildar Amankulov ([email protected])
droxi [email protected]:/>
I've tested some commands and never saw exitcode !=0 even when failed:
% droxi share blahblah
share: blahblah: no such file or directory (exitcode is 0)
Is it intended behaviour? Maybe we can use non-zero exitcode at least sometimes?
Currently there's only one account per user. I'd like a command line option or a keyword that lets me specify which account I want to connect to.
dropbox-uploader uses the -f option for this.
Please add a move with delete option to put. The move must behave atomically. The file must be deleted if the upload was successful. The file must not be deleted if the upload was not successful or was partial.
This is probably because cd is a builtin and droxi only looks for executables
For more entertainment try !mc, !vi, or !vim
I get this while trying to authorize:
This app is in development mode and can't accept more users. Contact the app developer and ask them to use the Dropbox API App Console to apply for production status.
Version : 0.2.3-1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.