From c89939b5d14e581e1aeaa940d81843192e0abc79 Mon Sep 17 00:00:00 2001 From: Christian Duerr Date: Fri, 19 Nov 2021 23:34:40 +0000 Subject: Switch to clap-generated completions The current completions required a lot of domain-specific knowledge about each individual shell and their completion functionality. Much of which is sparsely documented. While clap does not generate perfect completions, since parameters like `-e` are missing completions, it does a reasonable job while requiring no work on writing these completions. Since access to `cli.rs` isn't possible from the `build.rs`, these completions aren't always generated on build. Instead a test verifies that there has been no changes to these completions and provides a simple code sample for re-generating them. This should provide a simple solution with minimal overhead. --- Cargo.lock | 1 + 1 file changed, 1 insertion(+) (limited to 'Cargo.lock') diff --git a/Cargo.lock b/Cargo.lock index a49e8e51..71a09554 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -21,6 +21,7 @@ dependencies = [ "alacritty_config_derive", "alacritty_terminal", "bitflags", + "clap", "cocoa 0.24.0", "copypasta", "crossfont", -- cgit v1.2.3-54-g00ecf