github.com/xhghs/rclone@v1.51.1-0.20200430155106-e186a28cced8/docs/content/alias.md (about) 1 --- 2 title: "Alias" 3 description: "Remote Aliases" 4 date: "2018-01-30" 5 --- 6 7 <i class="fa fa-link"></i> Alias 8 ----------------------------------------- 9 10 The `alias` remote provides a new name for another remote. 11 12 Paths may be as deep as required or a local path, 13 eg `remote:directory/subdirectory` or `/directory/subdirectory`. 14 15 During the initial setup with `rclone config` you will specify the target 16 remote. The target remote can either be a local path or another remote. 17 18 Subfolders can be used in target remote. Assume a alias remote named `backup` 19 with the target `mydrive:private/backup`. Invoking `rclone mkdir backup:desktop` 20 is exactly the same as invoking `rclone mkdir mydrive:private/backup/desktop`. 21 22 There will be no special handling of paths containing `..` segments. 23 Invoking `rclone mkdir backup:../desktop` is exactly the same as invoking 24 `rclone mkdir mydrive:private/backup/../desktop`. 25 The empty path is not allowed as a remote. To alias the current directory 26 use `.` instead. 27 28 Here is an example of how to make a alias called `remote` for local folder. 29 First run: 30 31 rclone config 32 33 This will guide you through an interactive setup process: 34 35 ``` 36 No remotes found - make a new one 37 n) New remote 38 s) Set configuration password 39 q) Quit config 40 n/s/q> n 41 name> remote 42 Type of storage to configure. 43 Choose a number from below, or type in your own value 44 [snip] 45 XX / Alias for an existing remote 46 \ "alias" 47 [snip] 48 Storage> alias 49 Remote or path to alias. 50 Can be "myremote:path/to/dir", "myremote:bucket", "myremote:" or "/local/path". 51 remote> /mnt/storage/backup 52 Remote config 53 -------------------- 54 [remote] 55 remote = /mnt/storage/backup 56 -------------------- 57 y) Yes this is OK 58 e) Edit this remote 59 d) Delete this remote 60 y/e/d> y 61 Current remotes: 62 63 Name Type 64 ==== ==== 65 remote alias 66 67 e) Edit existing remote 68 n) New remote 69 d) Delete remote 70 r) Rename remote 71 c) Copy remote 72 s) Set configuration password 73 q) Quit config 74 e/n/d/r/c/s/q> q 75 ``` 76 77 Once configured you can then use `rclone` like this, 78 79 List directories in top level in `/mnt/storage/backup` 80 81 rclone lsd remote: 82 83 List all the files in `/mnt/storage/backup` 84 85 rclone ls remote: 86 87 Copy another local directory to the alias directory called source 88 89 rclone copy /home/source remote:source 90 91 <!--- autogenerated options start - DO NOT EDIT, instead edit fs.RegInfo in backend/alias/alias.go then run make backenddocs --> 92 ### Standard Options 93 94 Here are the standard options specific to alias (Alias for an existing remote). 95 96 #### --alias-remote 97 98 Remote or path to alias. 99 Can be "myremote:path/to/dir", "myremote:bucket", "myremote:" or "/local/path". 100 101 - Config: remote 102 - Env Var: RCLONE_ALIAS_REMOTE 103 - Type: string 104 - Default: "" 105 106 <!--- autogenerated options stop -->