mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 05:57:45 +00:00
pwd: Convert to serenity_main(..)
This commit is contained in:
parent
a62669ebcf
commit
81c98502f3
2 changed files with 8 additions and 7 deletions
|
@ -4,14 +4,14 @@
|
|||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <AK/Format.h>
|
||||
#include <AK/String.h>
|
||||
#include <LibCore/System.h>
|
||||
#include <LibMain/Main.h>
|
||||
|
||||
int main(int, char**)
|
||||
ErrorOr<int> serenity_main(Main::Arguments)
|
||||
{
|
||||
char* cwd = getcwd(nullptr, 0);
|
||||
puts(cwd);
|
||||
free(cwd);
|
||||
TRY(Core::System::pledge("stdio"));
|
||||
outln(TRY(Core::System::getcwd()));
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue