first commit

This commit is contained in:
Your Name 2024-07-01 13:23:00 +03:00
commit 21be7fd279
156 changed files with 6939 additions and 0 deletions

19
src/coreutils/pwd/pwd.c Normal file
View file

@ -0,0 +1,19 @@
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <limits.h>
#include <errno.h>
int main(void) {
char cwd[PATH_MAX];
if (getcwd(cwd, sizeof(cwd)))
puts(cwd);
else {
fprintf(stderr, "pwd: %s\n", strerror(errno));
return 1;
}
return 0;
}