# compilefile: Recompile one Erlang source file

Source: https://zotonic.com/docs/3010/compilefile-recompile-one-erlang-source-file

URI: https://zotonic.com/id/3010

Language: en

Recompile one Erlang source file.

Syntax
------

```text
bin/zotonic compilefile <path/to/file.erl>
```

Requirements and effects
------------------------

Requires a running node; passes the path to the file handler recompile operation.

Use the actual source path from the workspace. Check the returned result and compiler output. A single-file compilation may not cover changed dependencies or generated assets; use the normal build for those changes and then verify the affected behavior.

Example
-------

```sh
bin/zotonic compilefile apps_user/garden/src/garden.erl
```

Run commands from the Zotonic workspace root. Replace `garden` with your site name where applicable.

License: 

Attribution: 

Related resources: https://zotonic.com/api/agent/related/3010?language=en


## API access

- [API help](<https://zotonic.com/api-help>)
- [OpenAPI specification](<https://zotonic.com/openapi.json>)
- [This resource as JSON](<https://zotonic.com/api/agent/resource/3010?language=en>)
