You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 6, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+12-5Lines changed: 12 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,27 +27,34 @@ All of **bak**'s commands will disambiguate between multiple copies of the same
27
27
## Additional commands and flags
28
28
29
29
`bak down --keep my_file` - Restores from .bakfile, does not delete .bakfile
30
-
`bak diff my_file` Compare a .bakfile using `diff` (will become configurable)
30
+
`bak diff my_file` Compare a .bakfile using `diff` (configurable)
31
31
`bak list`/`bak list my_file` - List all .bakfiles, or just `my_file`'s
32
-
`bak open my_file` View a .bakfile in $PAGER
32
+
`bak open my_file` View a .bakfile in $PAGER (configurable)
33
33
`bak open --using exec my_file` View a .bakfile using `exec` (alias `--in`)
34
34
35
-
examples:
35
+
> examples:
36
36
37
37
bak open --using cat my_file.json
38
38
bak open --in nvim my_file.json
39
39
40
40
`bak get-bak my_file` Get the abspath of a .bakfile, in case, for some reason, you want to pipe it somewhere
41
41
42
-
example (for illustrative purposes; use 'bak diff' instead):
42
+
> example (for illustrative purposes; use 'bak diff' instead):
43
43
44
-
diff `bak get-bak my_file.json)` my_file.json
44
+
diff `bak get-bak my_file.json` my_file.json
45
45
46
46
## Current state (updated Jan. 20, 2020)
47
47
This is a very pre-alpha version, as in, this is a spaghetti proof-of-concept. Perhaps ~~5-6~~~~12-15~~ 20 hours have been spent on development so far. As such, it's only "working" in the strictest sense.
48
48
49
49
At the moment, **bak** stores its database and your bakfiles in `$XDG_DATA_HOME/bak`. If `$XDG_DATA_HOME` is not set, its specified default is used, and your stuff ends up in `~/.local/share/bak`.
50
50
51
+
The config file exists, but could be more intuitive. It's at `$XDG_CONFIG_HOME/bak.cfg` or `~/.config/bak.cfg` and currently accepts values for:
52
+
53
+
* The location of your .bakfiles and bakfile DB (I don't recommend changing this)
54
+
* The program to use by default for `bak open`
55
+
* The program to use by default for `bak diff` (at the moment, this must support typical `diff` syntax, as in `diff <file1> <file2>`)
56
+
* Whether `bak list` should display relative paths (defaults to False)
57
+
51
58
If the above sections suggest that a command is implemented, it's working at the most basic level. There are few sanity checks. Expect and please report bugs, as well as feature requests. If you're brave enough to work on a project in the early, mediocre phase, go nuts with the PRs.
52
59
53
60
Also, there's ~~no~~ very little exception handling (yet.)
0 commit comments