---
name: "foundry"
section: "1"
platform: "linux"
package: "foundry"
version: "1.2.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/foundry"
---

# foundry(1)

a command line development environment

## NAME

foundry - a command line development environment

## SYNOPSIS

**foundry** \[OPTION\]... COMMAND \[COMMAND-OPTIONS\]...\

## DESCRIPTION

**foundry** is a development environment and build system designed for the GNOME desktop. It provides project management, build pipeline integration, SDK management, and various development tools for building applications and libraries.

## COMMANDS

### Project Commands

- **init**

  Initialize a new project in the current directory.

### Environment Commands

- **enter**

  Enter the environment of the project in the current directory.

- **devenv \[-- command\]**

  Enter the build environment for the project similar to the build pipeline.

- **shell**

  Start a shell in the project environment.

### File Commands

- **guess-language FILE**

  Detect the programming language of a file.

- **grep PATTERN \[TARGET...\]**

  Grep files using the search and replace mechanism of Foundry.

- **symbol-tree FILE**

  List symbols in **FILE** as a tree.

- **find-symbol-at FILE LINE LINE\_OFFSET**

  Find the symbol at a specific position in **FILE** at **LINE** and **LINE\_OFFSET** (both starting from 1). Use **--tree** to print parent symbols as a tree.

- **ctags FILE**

  Index **FILE** using the ctags service and output the ctags data to stdout.

### Build Commands

- **build**

  Build the current build pipeline.

- **run \[-- command\]**

  Run a project command in the runtime environment.

### Pipeline Commands

- **pipeline info**

  Show information about the build pipeline.

- **pipeline flags FILE**

  Show the command used to compile a file.

- **pipeline targets**

  List build targets for the build pipeline.

- **pipeline which PROGRAM**

  Find a program in the build pipeline.

- **pipeline invalidate**

  Invalidate the pipeline cache.

- **pipeline link PHASE PROJECT\_DIRECTORY LINKED\_PHASE**

  Link a workspace to the build pipeline. The stage will run at **PHASE** of the current pipeline and execute the linked pipeline at **LINKED\_PHASE.**

- **pipeline unlink PHASE PROJECT\_DIRECTORY**

  Unlink a workspace from the build pipeline. Removes entries matching **PHASE** and **PROJECT\_DIRECTORY** from the linked workspaces.

### Configuration Commands

- **config list**

  List available configurations.

- **config switch CONFIG\_ID**

  Change the active configuration.

### SDK Commands

- **sdk list**

  List available SDKs.

- **sdk install SDK\_ID**

  Install a specific SDK.

- **sdk switch SDK\_ID**

  Change the active SDK for the build pipeline. This will update your current configuration to use the SDK when possible.

- **sdk shell SDK\_ID**

  Enter a shell in the SDK environment.

- **sdk which SDK\_ID PROGRAM**

  Show where **PROGRAM** is installed in **SDK\_ID**.

### Dependencies Commands

- **dependencies list**

  List project dependencies.

- **dependencies update**

  Update project dependencies. This does not build the dependencies. Use **foundry build** to build the dependencies.

### Device Commands

- **device list**

  List available devices.

- **device switch DEVICE\_ID**

  Switch the current target device.

### Deployment Commands

- **deploy**

  Deploy the project to the active device.

### Test Commands

- **test list**

  List available unit tests.

- **test run TEST\_ID**

  Run a unit test.

### Search Commands

- **search**

  Use global search engine to search across project.

- **show FILE**

  Open **FILE** in the preferred file browser.

### Settings Commands

- **settings get SCHEMA KEY**

  Get a setting value applying the priority of settings from the user overrides, project settings, and application-wide settings in that order.

- **settings set SCHEMA KEY VALUE**

  Set a setting value. Use **--global** to make the setting the user default. Use **--project** to make the setting the project default including other users who clone the project. Otherwise, the setting applies to the current user for the current project only.

### Secret Commands

- **secret get-api-key**HOSTNAME**SERVICE**

  Get an API key from the secret store. For example, **foundry secret get-api-key gitlab.gnome.org gitlab**

- **secret check-expires-at**HOSTNAME**SERVICE**

  Check when an API key expires for a service on a specific hostname. The expiration date will be printed in local timezone.

- **secret rotate**HOSTNAME**SERVICE**

  Rotate an API key for a service on a specific hostname. The API key will be rotated using a registered key rotator plugin and the new key will be stored securely.

- **secret set-api-key**HOSTNAME**SERVICE**API\_KEY

  Store an API key in the secret store.

### Diagnosis Commands

- **diagnose FILE**

  Diagnose issues with **FILE**

## CONDITIONAL COMMANDS

The following commands are only available when certain features are enabled at build time:

### Git Commands (requires feature-git)

- **clone URI**

  Clone a repository into a new project directory.

### Documentation Commands (requires feature-docs)

- **doc bundle install**

  Install a specific documentation bundle.

- **doc bundle list**

  List available documentation bundles.

- **doc query KEYWORD**

  Search for documentation.

### Forge Commands (requires feature-forge)

- **forge list**

  List available forge integrations.

- **forge issues list**

  List issues from the forge.

- **forge merge-requests list**

  List merge requests from the forge.

- **forge project**

  Show information about the forge project.

- **forge switch FORGE\_ID**

  - **forge switch --clear**

  Switch the active forge integration. Use **--clear** to clear the forge setting instead of setting it.

- **forge user**

  Show information about the forge user.

### Text Editing Commands (requires feature-text)

- **grep**

  Search for text patterns in source files.

### LLM Commands (requires feature-llm)

- **llm list-models**

  List available language models.

- **llm list-resources**

  List available resources.

- **llm list-tools**

  List available LLM tools.

- **llm complete MODEL PROMPT**

  Complete text using a language model.

### MCP Commands (requires feature-mcp)

- **mcp**

  Run MCP server. The server communicates via stdin/stdout using the Model Context Protocol.

### LSP Commands (requires feature-lsp)

- **lsp list**

  List available language server plugins.

- **lsp prefer PLUGIN LANGUAGE**

  Set preferred LSP for a language.

- **lsp run LANGUAGE**

  Run a language server for a specific language.

### Template Commands (requires feature-templates)

- **template create TEMPLATE\_ID\|TEMPLATE\_FILE**

  Create a new project from a template.

- **template list**

  List available project templates.

### Version Control Commands (requires feature-vcs)

- **vcs blame FILE**

  Show blame information for files.

- **vcs fetch REMOTE**

  Fetch changes from remote repositories.

- **vcs ignored FILE**

  Check whether a file is ignored.

- **vcs list**

  List version control information.

- **vcs list-branches**

  List branches in the repository.

- **vcs list-files**

  List files tracked by version control.

- **vcs list-remotes**

  List remote repositories.

- **vcs list-tags**

  List tags in the repository.

- **vcs log FILE**

  Show commit history for FILE.

- **vcs switch VCS\_ID**

  Switch the active version control implementation.

## OPTIONS

- **--shared**

  Use shared mode for the command.

- **-h**, **--help**

  Show help information for the command.

## EXAMPLES

Initialize a new project:

**foundry init**

Build the project:

**foundry build**

Run a project command:

**foundry run**

Enter the build environment:

**foundry devenv**

List available SDKs:

**foundry sdk list**

Install an SDK:

**foundry sdk install org.gnome.Sdk/x86\_64/master**

Start a language server:

**foundry lsp run python3**

## FEATURES

Foundry may be compiled with various features disabled or removed. Some commands may be unavailable if the underlying feature was not compiled into your version of Foundry.

## SEE ALSO

For further information, visit the website https://devsuite.app/

## BUGS

Bug reports can be found and filed at https://gitlab.gnome.org/chergert/foundry/issues
