EC_COMP_ITEM_SET_COMPLETION(3)
π ec_comp_item_set_completion β bestie edition π
okay so this page lives in the Libecoli Programmer's Manual, section 3, and it's literally about one thing: setting the completion value of an item. that's it. that's the whole vibe. let's go π«Ά
β¨ NAME β¨
ec_comp_item_set_completion β Set the completion value of an item.
like. the name tells you everything. no cap. π
πΈ SYNOPSIS πΈ
#include <ecoli/complete.h>
int ec_comp_item_set_completion(
struct ec_comp_item *item, /* The completion item to update. */
const char *completion /* The new completion string. */
);
so you roll up with a struct ec_comp_item * β that's the item you're updating, bestie β and a const char * holding your brand new completion string. two args, zero drama. π
π¦ DESCRIPTION π¦
okay so listen. the completion string is the thing that actually gets added to the incomplete token to complete it. it's the glow-up your half-typed word has been waiting for. β¨
and here's the tea: some nodes β sh_lex being the main character here β will modify that completion string in the items generated by their children. why? for stuff like adding a terminating quote. yeah. it's giving "I raised you and now I'm doing your hair before you go out." πββοΈ
π RETURN VALUE π
0β success!! slay!! everything ate, nothing left on the plate π½οΈβ¨-1β error π and nglerrnogets set, so go read it, it's telling you what went wrong fr fr
π SEE ALSO π
the whole friend group, no one left behind, we're all linked together:
ec_comp_add_item(3)ec_comp_count(3)ec_comp_item_set_str(3)ec_complete(3)ec_comp_get_attrs(3)ec_comp_group_get_attrs(3)ec_comp_iter_next(3)ec_comp_item_get_node(3)ec_comp_iter_first(3)ec_comp_item_get_current(3)ec_comp_group_get_node(3)ec_complete_strvec_expand(3)ec_comp_free(3)ec_comp_get_cur_pstate(3)ec_complete_unknown(3)ec_complete_strvec(3)ec_comp_item_get_grp(3)ec_comp_item_get_type(3)ec_comp_item_get_str(3)ec_comp_item_set_display(3)ec_complete_child(3)ec_comp(3)ec_comp_item_get_display(3)ec_comp_item_get_completion(3)ec_comp_group_get_pstate(3)ec_comp_dump(3)ec_comp_merge(3)ec_comp_get_cur_group(3)
π COPYRIGHT π
Copyright (C) 2010-2026 Olivier Matz, Robin Jarry.
okay that's the whole page bestie, tysm for reading, this was libecoli, dated 2026-06-11, and yes it's an EC_COMP_I...COMPLETION(3) situation. mwah. π go complete something iconic today πβ
π¦ where this page comes from
- fedora 44: libecoli-devel 0.11.7-1.fc44 Β· BSD-3-Clause AND LicenseRef-Fedora-Public-Domain
- fedora 44: libecoli-devel 0.11.7-1.fc44 Β· BSD-3-Clause AND LicenseRef-Fedora-Public-Domain
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms