aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md72
1 files changed, 72 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..d1b51bc
--- /dev/null
+++ b/README.md
@@ -0,0 +1,72 @@
1# dotup
2A CLI tool to help symlink your dotfiles into place.
3
4## Usage
5Example file hierarchy with dotfiles.
6```
7 configs
8 nvim/
9 init.vim
10 lua/
11 setup.lua
12 alacritty/
13 alacritty.yml
14 bash/
15 .bashrc
16 scripts/
17 script1.sh
18 script2.sh
19 script3.sh
20```
21
22### dotup init
23Running `dotup init` will create an empty depot file in the current directory(by default).
24```
25$ dotup init
26```
27A new file, `depot.toml`, should have been created in the current directory.
28
29### dotup link
30The `link` subcommand can be used to tell where a file should be linked when installed.
31Running `dotup link nvim .config/nvim` will create two new links:
32+ `nvim/init.vim` -> `.config/nvim/init.vim`
33+ `nvim/lua/setup.lua` -> `.config/nvim/lua/setup.lua`
34This subcommand will, by default, only link files. If a directory is passed as argument then it will recursively link all files under that directory.
35
36To link a directory use the flag `--directory`.
37```
38$ dotup link --directory scripts .scripts
39```
40This will create a new link
41+ `scripts` -> `.scripts`
42
43### dotup unlink
44The `unlink` subcommand unlinks files.
45```
46$ dotup unlink nvim/lua/setup.lua
47```
48will remove the link `nvim/lua/setup.lua` -> `.config/nvim/lua/setup.lua`.
49
50### dotup install
51The `install` subcommand creates symlinks.
52Like the `link` subcommand passing a directory as argument will recursively install anything under it, files and directories.
53
54By default install will use the home directory as the install-base but this can be changed with the `--install-base <path>` parameter.
55```
56$ dotup install nvim
57```
58will create two symlinks
59+ `nvim/init.vim` -> `$HOME/.config/nvim/init.vim`
60+ `nvim/lua/setup.lua` -> `$HOME/.config/nvim/lua/setup.lua`
61
62```
63$ dotup install scripts
64```
65will create one symlink
66+ `scripts` -> `$HOME/.scripts`
67Any new scripts added to `$HOME/.scripts` will be created at `configs/scripts`.
68
69### dotup uninstall
70The `uninstall` subcommand removes the symlinks.
71This will only remove symlinks if they were pointing to the correct file.
72