acton func2tolk
Reference manual for the acton func2tolk command
Synopsis
acton func2tolk [options] path
Description
Convert a FunC source file or a directory of FunC files into Tolk.
Acton shells out to npx and runs the upstream
@ton/convert-func-to-tolk package. Standard input, output, and error are
forwarded directly to the converter process.
Options
Conversion Options
Path to a .fc or .func file, or to a directory containing such files.
Write converted output to the specified path.
Insert warning comments into the generated output instead of reporting warnings only on stderr.
Disable snake_case to camelCase renaming.
Version of @ton/convert-func-to-tolk to execute.
Display Options
Control when to use colored output.
auto, always, never
Project Options
Accepted as a global Acton option for CLI consistency.
This command does not require an existing project manifest for its primary
workflow. It remains mutually exclusive with --project-root.
Accepted as a global Acton option for CLI consistency.
This command does not require an existing project root for its primary
workflow. It remains mutually exclusive with --manifest-path.
Requirements
This command requires:
- Node.js
- npm
npxavailable inPATH
Acton uses a temporary npm cache directory for each invocation.
That means converter downloads are not reused across runs.
Process Model
Acton runs:
npx --yes @ton/convert-func-to-tolk@<version> ...If the converter exits non-zero, acton func2tolk fails with the same outcome
reported as an Acton error.
If _path_ is a directory, file naming and directory traversal are delegated
to the upstream converter. --output is forwarded directly to that tool.
Exit Status
0: Conversion completed successfully, including runs that produced warnings.1:npxor the converter could not be started, conversion failed, or the requested output could not be written by the converter.
Examples
-
Convert all FunC files in a directory:
acton func2tolk contracts -
Convert a single file and keep warnings inline:
acton func2tolk jetton-minter.fc --warnings-as-comments -
Disable camelCase renaming:
acton func2tolk jetton-minter.fc --no-camel-case -
Use a specific converter version:
acton func2tolk jetton-minter.fc --version 1.0.0 -
Convert into an explicit output file:
acton func2tolk jetton-minter.fc --output jetton-minter.tolk
See Also
Last updated on