Day 16: Making tab completion setup seamless for users (App::shcompgen)
About the series: perlancar's 2014 Advent Calendar: Introduction to a selection of 24 modules which I published in 2014. Table of contents.
I've created a couple of frameworks that make it easy for Perl developers to add tab completion feature to their scripts (and am planning to write another one). One is Perinci::CmdLine, which I recommend and use a lot more myself but requires you to immerse yourself with the concepts Rinci metadata, Riap URLs, and all that. Another is Getopt::Long::Complete which is more suitable to casual Perl programmers familiar with de-facto and builtin module for options parsing in Perl, Getopt::Long. Getopt::Long::Complete allows you to use Getopt::Long interface; you just need to add a subroutine to tell how to complete option values and arguments.