# update main function to accept args and environ · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/85e8cc8abcd2b3fe1112d1a3c48346dc1210fd6e)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 85e8cc8abcd2b3fe1112d1a3c48346dc1210fd6e

Requested commit: 85e8cc8abcd2b3fe1112d1a3c48346dc1210fd6e

Commit: 85e8cc8abcd2b3fe1112d1a3c48346dc1210fd6e

Tree: 60ae573d34d0d2147f8d349685a7eeb871de32c3

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
update main function to accept args and environ

Now `main` takes an `init: std.Init` parameter, and this is the only way
to access command line arguments and environment variables.

After a deprecation period, this will close #4524

```

## Parents

- [8a3aebaee0a68d037a6f311bc5c1b426e8e1884c](https://git.cafe/gitcafe/zig/commit/8a3aebaee0a68d037a6f311bc5c1b426e8e1884c?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/85e8cc8abcd2b3fe1112d1a3c48346dc1210fd6e?format=markdown)
