Commit graph

7 commits

Author SHA1 Message Date
Vincent Ambo
13b0f80e4f feat(treecrumbs): support for TOML
Similar to YAML, but with more weird keys and with sections.

Change-Id: I94d69d2f0e53366855ccb5d99a432c6a0361a910
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11126
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
Reviewed-by: tazjin <tazjin@tvl.su>
2024-03-10 19:35:46 +00:00
Vincent Ambo
6280706ecd feat(treecrumbs): support for JSON
Fairly similar to YAML, except with only one way of naming keys and
arrays.

Change-Id: Ic2fa539466d69af55b36401bb8c03f2c7edcd91d
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11112
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
2024-03-10 19:35:46 +00:00
Vincent Ambo
3b7e546dfc feat(treecrumbs): initial support for C++
Supports namespaces, functions, fields (including trailing return type
syntax) and so on.

One notable issue about this is that the tree-sitter parser for C++
returns the node *following* point if point is on whitespace, which
means that at the top-level of a namespace the crumbs will often show
the *next* function.

I'm against adding workarounds for stuff like that, so I'll just keep
it as is.

Change-Id: If7e71525c4e86e128157dd4eb17c130297ed1e0a
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11109
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
2024-03-10 19:35:46 +00:00
Vincent Ambo
470f7dfa45 refactor(treecrumbs): macro for language definitions
Adds a macro that provides a more convenient syntax for defining new
languages for treecrumbs (and that can also be easily used outside of
the core treecrumbs code).

This macro automatically takes care of compiling tree-sitter queries
for reuse.

Change-Id: I6a0b892a083c3f243e8b8f0e1c865a9a8a1a5cf5
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11107
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
2024-03-10 19:35:46 +00:00
Vincent Ambo
eeca6cd891 feat(emacs-pkgs/treecrumbs): support "JSON-style" YAML syntax
Makes crumbs work correctly for weird stuff like:

```yaml
foo:
  - { "bar": [ { baz: 1 }]}
```

Would be nice to have tests for this at some point.

Change-Id: I034e83318435404ef8613e439313dbb08865f228
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11105
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
2024-03-10 19:27:49 +00:00
Vincent Ambo
13cced5b84 feat(tools/emacs-pkgs): configure FSF_OWNERS file
This adds a separate owners file that can be imported in projects with
FSF copyright assignment, so that only people with copyright paperwork
on file can commit (or verify commits before approving).

Change-Id: Ifbe07792572b9d6bf5f7d47c41135892bddea46b
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11108
Tested-by: BuildkiteCI
Reviewed-by: sterni <sternenseemann@systemli.org>
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: tazjin <tazjin@tvl.su>
2024-03-10 19:27:49 +00:00
Vincent Ambo
0be7b938c2 feat(emacs-pkgs/treecrumbs): tree-sitter based breadcrumbs
Adds a new 'treecrumbs' Emacs package that allows displaying fast,
tree-sitter based breadcrumbs. The initial version only supports
YAML (which is what I needed this for!).

The package is documented, please go read the code and comments for
more information.

I assign copyright over this package to the FSF, paperwork is on file.
This means that I can only accept contributions from people with the
right paperwork. If this package ends up being useful, I intend to
eventually submit it to GNU Emacs.

Change-Id: If1297a080f63f402f83b6cc57fa7c970d32d3695
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11104
Reviewed-by: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
Autosubmit: tazjin <tazjin@tvl.su>
2024-03-10 19:27:49 +00:00