atlog(3)
π atlog β log and lock handling, bestie edition β¨
ok so real talk, this page is about two little functions that handle comments and locks on your software objects. Their government names are atSetComment and atUnlock, and honestly? they're the duo of the century. π«Ά
β¨ SYNOPSIS β¨
#include <atfs.h>
#include <atfstk.h>
int atSetComment (Af_key *aso, int commentType, char *commentText, int mode);
int atUnlock (Af_key *aso);
πΈ DESCRIPTION πΈ
π atSetComment
atSetComment sets a comment attribute for the attributed software object aso. You pass it a commentType, and bestie, there are exactly three valid ones. Let's go:
AT_COMMENT_INTENTβ for expressing a change intent, aka describing the modifications you're planning to make. manifesting the diff fr fr β¨AT_COMMENT_DESCRβ for issuing a descriptive text expressing the purpose of the document. like, what IS this thing? πAT_COMMENT_LOGβ for writing a change log describing the changes actually made. receipts, periodt π
The commentText argument is where you can hand over a default text. Depending on the mode (more on that in a sec), the user gets asked to enter the comment attribute value. When a default text is given, it'll be offered up for modification. And when you pass in a commentText argument, the previous value of the corresponding comment attribute gets used as the default text. cute, right? π
π the mode field
With the mode field you can influence how atSetComment behaves. Three flags can be set:
AT_FROMSTDINβ advisesatSetCommentto read the user input from standard input. If you don't set this, an editor gets started instead. your choice bestie π§AT_REUSEβ causes reuse of the comment text expressed during the previous invocation ofatSetComment, if there was any. recycling is iconic πAT_CONFIRMβ lets the user confirm that a comment shall be expressed. Without it,atSetCommentjust asks for the comment text with no prior confirmation. Heads up though: this flag is ignored whenAT_FROMSTDINis set and the change comment is taken from standard input. so don't count on it there π
π atUnlock
atUnlock unlocks aso by calling af_unlock (peep the manual page af_lock(3) if you wanna go deeper). And if a change intent was previously set for aso? bestie, it gets eliminated. gone. poof. πβ¨
π DIAGNOSTICS π
atSetComment and atUnlock return FALSE (zero) on error. Not only that β the atError variable gets set, and afErrMsg holds a diagnostic message. so like, you'll know. the vibes will be off and the error message will tell you why π₯
π¦ ENVIRONMENT π¦
EDITORβ the default editor to be called. pick your fighter π
π SEE ALSO π
and that's the whole page, no notes. go forth and comment responsibly. πΈ
this was brought to you by AtFStk-1.12, dated Fri Jun 25 16:39:38 1993 β yeah it's vintage, it's archival, it's giving β¨timelessβ¨. mwah π
π¦ where this page comes from
- debian bookworm: atfs-dev 1.4pl6-15+b1
- ubuntu jammy: atfs-dev 1.4pl6-15
- ubuntu noble: atfs-dev 1.4pl6-16.1build1
- ubuntu resolute: atfs-dev 1.4pl6-17
- ubuntu stonking: atfs-dev 1.4pl6-17
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms