Commit graph

319 commits

Author SHA1 Message Date
Denis Isidoro
3f66614818 Bump 2020-03-16 10:22:37 -03:00
Denis Isidoro
7eccec0a51 linting 2020-03-16 08:14:02 -03:00
Denis Isidoro
dd6c54f089 wip 2020-03-16 08:13:55 -03:00
Denis Isidoro
ebcdb8d162 linting 2020-03-16 08:02:52 -03:00
Denis Isidoro
fcfa7843fc wip 2020-03-16 08:02:23 -03:00
Denis Isidoro
92cf10d10a
Allow repos with @ (#272) 2020-03-15 22:13:18 -03:00
Denis Isidoro
07134996e4
Use data_dir for cheats 2020-03-15 20:26:48 -03:00
Denis Isidoro
de16846aba
Initial cheat repo support (#258)
This PR makes navi stop bundling `.cheat` files and makes it able to download from repos on GitHub, using a standardized config directory.

- it fixes #233 and #237
- it makes #52, #256 and #257 much easier to implement
- it makes #40 harder to implement
- it's an alternate solution to #140 
- it's influenced by #238 and #254.

This PR ended up being much bigger than I would like so if you could review only this description it would be already very nice!

When navi is started for the first time, a welcome cheatsheet is shown:
![Screenshot at 2020-03-15 10-20-04](https://user-images.githubusercontent.com/3226564/76702240-19fffd80-66a7-11ea-884f-97c565bc1ead.png)

If the user selects the first option, the user is prompted to download `.cheat`s from https://github.com/denisidoro/cheats: 
![Screenshot at 2020-03-15 10-20-35](https://user-images.githubusercontent.com/3226564/76702239-19fffd80-66a7-11ea-8f69-324f669b1e01.png)
![Screenshot at 2020-03-15 10-22-59](https://user-images.githubusercontent.com/3226564/76702236-18363a00-66a7-11ea-8ff4-53b497f85888.png)

The config folder is populated:
![Screenshot at 2020-03-15 10-21-11](https://user-images.githubusercontent.com/3226564/76702238-19676700-66a7-11ea-8367-3e7b5733f2b4.png)

When run again, cheats are available:
![Screenshot at 2020-03-15 10-21-34](https://user-images.githubusercontent.com/3226564/76702237-19676700-66a7-11ea-9c2a-d8829340f3e9.png)

### Breaking changes

In order to make navi stop bundling shell widgets as well, a breaking change has been introduced: `source $(navi widget bash)` won't work anymore. It should be `source <(navi widget bash)` now. Any ideas on how to make this transition more graceful?
2020-03-15 13:46:58 -03:00
Denis Isidoro
48c2b64f7f
Static newline regex (#264) 2020-03-14 18:22:39 -03:00
asd
1678564800 💅 2020-03-14 18:14:30 -03:00
Denis Isidoro
3fa141846b
Allow multiline commands (#262)
Fixes #260
2020-03-14 18:08:57 -03:00
Denis Isidoro
5423cd8ccb
wip (#261) 2020-03-14 15:34:26 -03:00
Ingolf Wagner
0d22fe49ab
pull request comments 2020-03-14 23:46:33 +08:00
Ingolf Wagner
3617126f6a
cosmetics 2020-03-14 20:53:27 +08:00
Ingolf Wagner
af6fba3c31
run cargo fmt 2020-03-14 20:33:07 +08:00
Ingolf Wagner
0a22398a47
add --allow-extra option 2020-03-14 20:32:00 +08:00
Ingolf Wagner
8669ba9829
changed suggestion processing and signaling for fzf 2020-03-14 20:32:00 +08:00
Ingolf Wagner
50627492f3
minor refactorings 2020-03-14 20:31:59 +08:00
Ingolf Wagner
6f4c5ba25b
add variable name to prompt with suggestions 2020-03-14 03:22:57 +08:00
Denis Isidoro
e40a0e2dc4
Reuse variables (#252)
Fixes #251
2020-03-13 08:27:19 -03:00
Denis Isidoro
f8e8da018b
Minor theme change (#246) 2020-03-12 23:58:51 -03:00
Denis Isidoro
7f4fc90116
Prevent panic when there are no cheats (#244)
Fixes #243
2020-03-12 23:32:28 -03:00
Denis Isidoro
f6a4fec13d
Add support for variable dependency (#242)
Fixes #203
2020-03-12 21:39:15 -03:00
Denis Isidoro
c5b3b175f6
Add support for navi fn (#241)
Fixes #208
2020-03-12 21:05:18 -03:00
Denis Isidoro
e32e0f1245
Fix delimiter (#239)
Fixes #230
2020-03-12 19:04:47 -03:00
Denis Isidoro
60a77e828a
Merge branch 'master' into fix-badcmd 2020-03-12 17:43:34 -03:00
Denis Isidoro
0f8b9853b6 Bump 2020-03-12 17:42:56 -03:00
Austin Jones
41951e22a4 Fix crash when user enters a command that doesn't exist 2020-03-12 14:16:56 -04:00
Denis Isidoro
ce9c22100a
Allow overriding FZF variables (#235)
`$FZF_DEFAULT_OPTS` won't work in some use cases because it has lower precedence then hardcoded settings such as `--exact`.

Usage:
```
export NAVI_FZF_OVERRIDES=" --no-exact"
navi
```

Fixes #232
2020-03-12 14:57:02 -03:00
Denis Isidoro
a1dea118c0
Fix path issues (#231)
Fixes #224 and #228
2020-03-12 13:03:04 -03:00
Denis Isidoro
770793317b
Handle relative symlinks (#225)
Attempts to solve #224 and #223
2020-03-11 20:26:00 -03:00
Denis Isidoro
06eae50613
Minor fixes (#221) 2020-03-11 11:30:25 -03:00
Denis Isidoro
751393309f
Defensive cheats folder (#220) 2020-03-10 14:01:28 -03:00
Denis Isidoro
44d072de94
Be more defensive with /dev/tty (#219) 2020-03-10 13:32:22 -03:00
Denis Isidoro
4a1bbd39ab
Add support for metacomment (#216)
Fixes https://github.com/denisidoro/navi/issues/215
2020-03-09 15:02:54 -03:00
Denis Isidoro
233f5ca8c1 Terminal width fallback 2020-03-09 13:57:48 -03:00
asd
44d3d1bec8 Fix linting 2020-03-07 18:37:35 -03:00
Denis Isidoro
62e0d2cb94
Move code to fzf.rs 2020-03-07 18:08:31 -03:00
Denis Isidoro
ac61dd09b4
Fix use in subshell (#213) 2020-03-07 18:03:51 -03:00
Denis Isidoro
dc4fe98f56
Fix best command (#210) 2020-03-05 17:40:14 -03:00
Denis Isidoro
fe26b00953
Follow symlinks for exe (#209) 2020-03-05 16:29:49 -03:00
Denis Isidoro
c5cd85bb41
Rust implementation (#197) 2020-03-04 18:01:23 -03:00
bitozoid
cf7201af7a
Limit dep order filter
To fix #182.
2020-02-03 10:42:51 +00:00
Denis Isidoro
dbcd7eae4a
Revert "Correctly escape backslashes" (#181)
Reverts #177

Fixes #179 but reopens #131
2020-01-22 17:26:25 -03:00
Denis Isidoro
e9dc75555b
Correctly escape backslashes (#177)
Fixes #131
2020-01-20 16:44:21 -03:00
Denis Isidoro
a70c6dfadd
Add support for multiple choice (#175)
Fixes #173
2020-01-17 15:29:16 -03:00
Denis Isidoro
8f2bc5f7e7
Fish: fix widget (#174)
Fixes #170 and #171
2020-01-17 14:41:23 -03:00
Denis Isidoro
ac39ac630c Bump to 0.17.0 2019-12-17 13:36:57 -03:00
Dawid Dziurla
7bc7f2304f
Fix preview in fish shell 2019-12-16 16:03:01 +01:00
Denis Isidoro
0b2e67c3d0
Add bindings for C-j and C-k (#165)
Fixes #164
2019-12-09 11:08:24 -03:00