contour
contour copied to clipboard
WIP: towards detecting arbitrary URLs and make them clickable
Closes #1078 Closes #421
this PR is of course not even remotely usable yet, but it's here to track the progress.
Checklist
Checklist for implementing this could look like:
- [x] regex_dfa: integrate DFA regular expression engine from klex project
- [x] regex_dfa: adapt to get all compiler diagnostics green
- [x] regex_dfa: integrate tests
- [ ] auto-detect URL patterns in the grid buffer
- [ ] vim mode:
gxto open the URI (or file) underneath the cursor position - [ ] vim mode:
]xto jump to next and[xto jump to previous URI (or file) in screen's grid buffer - [ ] allow customising how to detect what an URI is via a regex through the config file (profile).
- [ ] visually differentiate matches (just like search/click matches) to make cycling through them and quickly identifying them visually more appealing
- [ ] support matching URLs as well as local filepaths, into a single DFA
- [ ] support caching the compiled DFA onto disk (with a checksum to ensure it wasn't tempered with) and reload that on next startup to avoid slowing down startup-times.