MDEX_BASEDIR(3)

πŸ’– MDEX_BASEDIR(3) πŸ’–

okay bestie, welcome to the Librecast Programmer's Manual section 3, and today's main character is mdex_basedir πŸŽ€ she's a little function with one job and she does it flawlessly, no cap.


✨ NAME ✨

mdex_basedir β€” set the base directory for a multicast index πŸ—‚οΈβœ¨


πŸ“š LIBRARY πŸ“š

Librecast library (liblibrecast, -llibrecast) 🫢


🌸 SYNOPSIS 🌸

#include <librecast/mdex.h>

void mdex_basedir(mdex_t *mdex, char *basedir);

Compile and link with -llibrecast.


πŸ’… DESCRIPTION πŸ’…

so the way this works is: mdex_basedir sets the base directory for mdex to basedir. simple. iconic. she's not doing side quests.

and here's the slay part β€” that basedir gets stripped from the beginning of all the files added to the index with mdex_addfile(3). so like, you set the base, and every path after that gets its lil prefix trimmed off before it lands in the index. it's giving "clean up your paths" energy βœ¨πŸ¦‹


🫧 RETURN VALUE 🫧

mdex_basedir() returns no value. she gives nothing back, and honestly? valid. πŸ’…


πŸ’€ ERRORS πŸ’€

None. zero. nada. not a single error to report. she simply cannot fail, and we love that for her πŸ˜­πŸ‘‘


πŸ‘€ SEE ALSO πŸ‘€


Librecast 🌈 β€” dated 2023-07-23 β€” that's the version and the vibe, mwah πŸ’‹ go forth and set your base directory, bestie 🫢✨

πŸ“¦ where this page comes from