Commit Graph

76 Commits

Author SHA1 Message Date
Arijit Basu
0584a43c7c Add SwitchModeBuiltin and SwitchModeCustom
Also, use a better prompt symbol.

Ref: https://github.com/sayanarijit/xplr/issues/107
2021-05-07 20:08:52 +05:30
Arijit Basu
2c7ec47253 Fix cd on first focus
Fix issue where running `xplr /path/to/file` doesn't `cd` into the
parent directory.
2021-05-01 20:31:46 +05:30
Arijit Basu
1c967cfef6 Update version 2021-04-30 17:40:51 +05:30
Arijit Basu
36af3e8ced Fix pipes not updating properly
Let's not optimize things until we have tests.
2021-04-29 08:27:56 +05:30
Arijit Basu
4dad10815a Fix support for filenames starting with - (hiphen)
Make it possible to create, delete, copy, move, rename filenames starting
with a - (hiphen).
2021-04-28 08:09:40 +05:30
Arijit Basu
2437fd67cf Fix distorted screen when opening files in GUI
Fixes: https://github.com/sayanarijit/xplr/issues/111
2021-04-27 23:58:00 +05:30
Arijit Basu
eca35c73a2 Update version 2021-04-24 22:22:32 +05:30
Arijit Basu
e9b5dfe478 Fix incompatible config version
Fixes: https://github.com/sayanarijit/xplr/issues/97
2021-04-23 11:04:58 +05:30
Arijit Basu
36c2c9cc2b
Update version 2021-04-23 00:17:43 +05:30
Arijit Basu
1ffa85f30f Do not exit on permission denial
While trying to enter restricted directories, log error instead or
exiting.
2021-04-21 08:28:02 +05:30
Arijit Basu
ad3dd8eec2
Update version 2021-04-20 21:20:28 +05:30
Arijit Basu
c11099f651 Fix follow symlink behavior.
Use `gf` to follow symlinks instead of `enter`/`l`.

Or use the message `FollowSymlink`.
2021-04-19 23:23:28 +05:30
Arijit Basu
87cd6ff015 Fix global help menu not displaying sort & filter 2021-04-19 21:01:20 +05:30
Arijit Basu
f8fb6913c9 Rework README.md, Cargo.toml 2021-04-19 19:20:51 +05:30
Arijit Basu
ca13ebb193 Added inode size
Also supports sorting by inode size.

Closes: https://github.com/sayanarijit/xplr/issues/84
2021-04-19 14:48:45 +05:30
Arijit Basu
a8896740c8 Add sorting support
Also improve filtering.

Closes: https://github.com/sayanarijit/xplr/issues/58
2021-04-18 16:14:17 +05:30
Arijit Basu
d0342260fe Add support for NO_COLOR
Also, add `general.logs` to the config.

Ref: https://no-color.org/
2021-04-14 08:38:00 +05:30
Arijit Basu
ea42b1969a Improve scrolling behaviour
Closes: https://github.com/sayanarijit/xplr/issues/54
2021-04-12 21:51:59 +05:30
Arijit Basu
49ffd8e1f1 Fix exit error codes
Also remove cucumber-rust (will try https://github.com/rust-rspec/rspec)

Fixes: https://github.com/sayanarijit/xplr/issues/33
2021-04-12 11:13:31 +05:30
Arijit Basu
f247acf626 Fix remap behaviour and help menu
Remapping a key should overwrite default. Also, remapped keys shouldn't
be redundantly visible in help menu.

Also, display log time.
2021-04-11 22:22:36 +05:30
Arijit Basu
d34dc77ea5 Initial BDD testing setup 2021-04-11 21:15:01 +05:30
Arijit Basu
080e1686f3 Improve version compatibility
From this version, xplr won't annoy the users to visit the upgrade guide
when there is no need.

Also, users will only get upgrade related notification when it is
there is one.
2021-04-11 21:15:01 +05:30
Arijit Basu
6aa3df301e Separate config.yml file from rust files
Also be less aggressive for version compatibility.

Use the following logic:

Knowing that we use `{major}.{minor}.{patch}` versioning,

- Major version mismatch are incompatible. Fail with error, suggesting to
  visit the Upgrade Guide.
- Minor version updates and patch fixes are compatible. Suggest user to
  update the config file version manually. Or visit the Upgrade Guide.

- However, if the config file has greater value for minor version
  than the app, also fail with error. Suggesting the user to visit Upgrade
  Guide. Though in this case, the user will be downgrading.

Ref: https://github.com/sayanarijit/xplr/issues/45
2021-04-09 23:57:39 +05:30
Arijit Basu
233f6d44a5
Update version 2021-04-09 16:26:45 +05:30
Arijit Basu
b9e9601a71
Fix failed build and update version 2021-04-09 08:21:30 +05:30
Arijit Basu
c06a3cb51e
Update version 2021-04-09 04:19:26 +05:30
Arijit Basu
6d0ea06d7b Add pwd watcher
Also optimize the main thread.
2021-04-09 04:19:44 +05:30
Arijit Basu
0a3cf7b5c1
Update version 2021-04-09 01:29:38 +05:30
Arijit Basu
fa37cd1c10 Improve search and filter
Concern:
Using `ResetNodeFilters` to clear the filters while searching or exiting
from search unexpectedly resets the `show hidden` mode because the
action not only removes the target filter, it resets all the other
filters as well.

Solution:
Implement `RemoveNodeFilterFromInput` to be able to clear or remove
target filters without having to reset it.
2021-04-08 08:01:10 +05:30
Arijit Basu
91a319fc80
Update version 2021-04-07 19:57:25 +05:30
Arijit Basu
23b51cf8fe
Fix failed build and re-publish 2021-04-07 03:06:47 +05:30
Arijit Basu
2bd2b743fb
Fix renaming 2021-04-07 02:42:20 +05:30
Arijit Basu
e34755b11b Update version
Also fix nix hash
2021-04-07 01:59:02 +05:30
Arijit Basu
65ddb0ee4b
Release 0.3.2 2021-04-06 18:55:57 +05:30
Quentin Guilloteau
a9309a52c0 add comment to remind to update the version in the default.nix file 2021-04-06 16:59:58 +05:30
Arijit Basu
eeee3394bc Improve version incompatibility error
With this change, `xplr` will only raise version incompatibility error
if the major version changes. Minor version updates are assumed to be
backwards compatible.

If the major version is `v0`, the minor version will be considered as
the major version and the security/patch version will be considered as
minor version and the same logic will apply.
2021-04-06 06:43:51 +05:30
Arijit Basu
981ead8c36 Fix large env vars breaking the subprocess
Bug:
When you call some command in a directory with a large number of hosts,
xplr will fail setting the environment vars as the command will become
too large to handle.

Fix:
Port the value of multi-line variables from env vars to pipes and set
the name of the pipe as env var instead. And deprecate the variables
that doesn't make much sense.

In other words,

- `$XPLR_APP_YAML` has been removed.
- `$XPLR_RESULT` has been ported to `$XPLR_PIPE_RESULT_OUT`.
- `$XPLR_GLOBAL_HELP_MENU` has been ported to
  `$XPLR_PIPE_GLOBAL_HELP_MENU_OUT`.
- `$XPLR_DIRECTORY_NODES` has been ported to
  `$XPLR_PIPE_DIRECTORY_NODES_OUT`.
- `$XPLR_LOGS` has been ported to `$XPLR_PIPE_LOGS_OUT`.
- `$XPLR_PIPE_RESULT` has been ported to `$XPLR_PIPE_RESULT_OUT`.

Hence, instead of `<<< $VAR`, `< $VAR_PIPE_OUT` should be used.
2021-04-05 20:28:35 +05:30
Arijit Basu
9747c8667b Autocomplete the relative path while renaming
By default, while renaming a file, autocomplete the relative path i.e.
the filename instead of the absolute path in the input buffer.
2021-04-05 13:50:53 +05:30
Arijit Basu
67f2094a4c Autorefresh, BashExec and basename
- Auto `Refresh` every second.
- Add alias `BashExec` to message `Call` with args [`-c`, `bash` ...].

Also, Create alias `BashExec` to message `Call` with arguments [`bash`, `-c`]
2021-04-05 12:51:31 +05:30
Arijit Basu
8dae2fef4d
Add native support for renaming 2021-04-04 16:47:03 +05:30
Arijit Basu
2432673483
Log error if command fails 2021-04-04 15:18:13 +05:30
Arijit Basu
b03618737c
Remove skim from dependency 2021-04-04 11:56:44 +05:30
Arijit Basu
4d2caf512e
Log explorer errors 2021-04-04 10:05:52 +05:30
Arijit Basu
e93e815bc4
Add upgrade instructions for incompatibility error 2021-04-04 09:17:53 +05:30
Arijit Basu
a11dca5a1c
Finish documenting the messages 2021-04-04 08:54:42 +05:30
Arijit Basu
af8a637030
Logging, testing and other improvements 2021-04-03 11:32:05 +05:30
Arijit Basu
71a23e1f64
Implement native search and filter 2021-04-03 06:49:59 +05:30
Arijit Basu
7cbb9d2baf
Saner key bindings 2021-04-02 19:56:18 +05:30
Arijit Basu
c0ca596539
Fix create mode, refactor readers, fix init focus 2021-04-02 18:03:56 +05:30
Arijit Basu
3990200232
Anyhow handle errors 2021-04-02 17:11:18 +05:30