grp.h(0P)
πΈ PROLOG πΈ
okay bestie, tiny heads up before we get into it π this manual page is part of the POSIX Programmer's Manual. the Linux implementation of this interface may differ (consult the corresponding Linux manual page for details of Linux behavior), or the interface may not be implemented on Linux at all π so likeβ¦ vibe check your platform first, fr fr.
π NAME π
grp.h β group structure. that's it. that's the name. short, sweet, iconic π
β¨ SYNOPSIS β¨
#include <grp.h>
like, that's the whole move. one include and you're in π«Ά
π DESCRIPTION π
so the <grp.h> header shall declare the group structure, and that structure shall include these members:
char *gr_name The name of the group.
gid_t gr_gid Numerical group ID.
char **gr_mem Pointer to a null-terminated array of character
pointers to member names.
periodt. gr_name is the name of the group, gr_gid is the numerical group ID, and gr_mem is a pointer to a null-terminated array of character pointers to member names πΈ
and bestie, the <grp.h> header shall also define the gid_t and size_t types as described in <sys/types.h> β so that's where those cuties come from π₯
now the main character energy: the following shall be declared as functions and may also be defined as macros. function prototypes shall be provided. (yes, both. it's giving versatile π )
void endgrent(void);
struct group *getgrent(void);
struct group *getgrgid(gid_t);
int getgrgid_r(gid_t, struct group *, char *,
size_t, struct group **);
struct group *getgrnam(const char *);
int getgrnam_r(const char *, struct group *, char *,
size_t , struct group **);
void setgrent(void);
okay and just so you know β the following sections are informative. (that's their whole thing, they're the chill informative ones, not the rules-rules ones π)
π APPLICATION USAGE π
None.
like, literally none. nothing to add. the page said what it said π
π¦ RATIONALE π¦
None.
nope, no rationale here either. it's giving mystery, it's giving "we just didn't" β¨
π FUTURE DIRECTIONS π
None.
no future plans bestie, this is the final form π«Ά
π SEE ALSO π
<sys_types.h>- The System Interfaces volume of POSIX.1β2017,
endgrent(),getgrgid(),getgrnam()
go read those if you wanna go deeper, iykyk π
π COPYRIGHT π
Portions of this text are reprinted and reproduced in electronic form from IEEE Std 1003.1-2017, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 7, 2018 Edition, Copyright (C) 2018 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between this version and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html .
Any typographical or formatting errors that appear in this page are most likely to have been introduced during the conversion of the source files to man page format. To report such errors, see https://www.kernel.org/doc/man-pages/reporting_bugs.html .
ok bestie that's the whole legal situation, no cap β if something looks off between this page and the actual Standard, the Standard wins, periodt π
and that's the page!! mwah π this lil masterpiece came from IEEE/The Open Group, dated 2017, and it lives at grp.h(0P) β slay, ate, no crumbs, see you in the next man page bestie πβ¨
π¦ where this page comes from
- alpine 3.22: man-pages-posix 2017a-r0 Β· custom
- alpine 3.23: man-pages-posix 2017a-r0 Β· custom
- alpine 3.24: man-pages-posix 2017a-r0 Β· custom
- arch rolling: man-pages 6.19-1
- arch rolling: man-pages 6.20-1 Β· BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
- nixpkgs unstable: man-pages-posix 2017a
- opensuse-leap 16.0: man-pages-posix 2017a-160000.4.1 Β· SUSE-IEEE
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms