# emacs-dropbox **Repository Path**: lorniu/emacs-dropbox ## Basic Information - **Project Name**: emacs-dropbox - **Description**: Dropbox client on Emacs - **Primary Language**: Emacs Lisp - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-02-17 - **Last Updated**: 2025-07-27 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT) # A Dropbox Client for Emacs This package provides a seamless way to interact with your Dropbox files directly within Emacs. It aims to offer a simple and efficient user experience by leveraging `Dired` for file management and employing `asynchronous` operations with `caching` for improved responsiveness. While other clients like [pavpanchekha/dropbox.el](https://github.com/pavpanchekha/dropbox.el) exist, this package was developed to address my personal needs, anyone else can take it as an alternative approach. ## Install & Setup Put the `dropbox.el` into your load-path. Or using `use-package` like this: ```emacs-lisp (use-package dropbox :vc (:url "https://github.com/lorniu/dropbox.el")) (use-package dropbox :vc (:url "https://github.com/lorniu/dropbox.el") :config (setq dropbox-config-file "~/.dropbox") (setq dropbox-http-backend (pdd-curl-backend))) ``` Before you can access your Dropbox files, you need an auth configuration file (`dropbox-config-file`): - The `~/.dropbox` generated by `dropbox_uploader.sh` can be reused, it's compatible. Do nothing if it exists - If you don't have a `~/.dropbox` file, run `M-x dropbox-gen-config`, following the guide to generate one ## Usage Once authenticated, you can interact with your Dropbox files. ### Accessing Files - **Open Remote Path**: Use `M-x find-file` (`C-x C-f`) with the special `/db:` prefix to open a remote Dropbox directory or file. + Example: `C-x C-f /db:/Apps/MyEmacsApp/notes.org` + Example: `C-x C-f /db:/Photos/2023/` - **Search and Open**: Use `M-x dropbox-find` to search for a file in your Dropbox and open it directly. ### Editing Remote Files Remote files are opened in local Emacs buffers. Edit the buffer as you normally would. When you save the buffer (`C-x C-s`), the changes are automatically uploaded and synchronized with the remote file on Dropbox. ### Dired Mode Operations When you open a remote Dropbox directory (e.g., `/db:/path/to/folder/`), it will be displayed in Dired mode. You can perform many standard Dired operations, which will be applied to your remote Dropbox files. e.g.: - `+`: Create a new directory on Dropbox - `C-x C-f path-not-exist.txt`: Create new file (sync when save) - `RET`: Open current file at point + With prefix `C-u`, open and cache to disk. The next time it will be opened from cache directly + Some files (according to `dropbox-cache-disk-url-regexp`) will auto cached into disk when be opened + Delete the cache on disk with `dropbox-clear-cache-on-disk` if necessary (with prefix `C-u` to clear all) - `C`: Copie file or directory between Dropbox and local + File copy from remote to local is also called `download`, from local to remote is also called `upload` + Directory copy from remote to local and named as `*.zip`, will be auto compressed and downloaded as a single file - `R`: Rename or move files/directories. The logic is similar to the C (Copy) command - `D`: Delete the marked remote file(s) or directory ### Other commands - `dropbox-browser`: Open the current Dropbox directory (or your Dropbox root if not in a Dropbox Dired buffer) in your default web browser. - `dropbox-revisions`: In a Dired mode or a remote file buffer, invoke this command will popup a buffer to view and operate the revisions (diff, download, restore and so on). - `dropbox-shared-link/dropbox-shared-link-revoke`: Generate/revoke a link for current remote file/dir, which can be shared with others. - `dropbox-download-link`: Generate a temporary link for current remote file, which can be used by download tool like `curl`. ## Miscellaneous Issues and PRs are welcome. Enjoy.