Creating a New Golem Project with golem new
Both golem and golem-cli can be used — all commands below work with either binary. The golem binary is a superset that includes a built-in local server.
Usage
Always use non-interactive mode by passing --yes (or -Y) and specifying --template:
golem new --template <LANGUAGE> --yes <APPLICATION_PATH>Arguments
| Argument | Description |
|---|---|
<APPLICATION_PATH> | Directory where the new application is created. The folder name becomes the application name by default. |
Required flags
| Flag | Description |
|---|---|
--template <LANGUAGE> | Language template to use. See supported languages below. |
--yes / -Y | Non-interactive mode — automatically accepts all confirmation prompts. Always use this flag. |
Optional flags
| Flag | Description |
|---|---|
--application-name <NAME> | Override the application name (defaults to the folder name). |
--component-name <NAMESPACE:NAME> | Set a specific component name. Must follow namespace:name format. Defaults to a name derived from the application name and language. |
--preset <PRESET> | Select a component preset. Generated projects come with debug and release presets by default (configured in golem.yaml). |
Supported languages
| Language | Template value |
|---|---|
| Rust | rust |
| TypeScript | ts |
| Scala | scala |
Examples
Create a new Rust project:
golem new --template rust --yes my-rust-appCreate a new TypeScript project:
golem new --template ts --yes my-ts-appCreate a new Scala project:
golem new --template scala --yes my-scala-appCreate a project with a custom application name:
golem new --template rust --application-name my-app --yes ./projects/my-appCreate a project with a specific component name:
golem new --template ts --component-name myns:my-component --yes my-appCreate a project with the release preset:
golem new --template rust --preset release --yes my-appLast updated on