# 使用 Homebrew, MacPorts 安装 gravity

查看 gravity 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:gravity
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install gravity
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install gravity
```

  证据: MacPorts ports tree: lang/gravity/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

## 软件包事实

- **软件包键:** brew:gravity
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/gravity>
- **版本:** 0.9.7
- **来源摘要:** Embeddable programming language
- **主页:** <https://www.gravity-lang.org/>
- **仓库:** <https://github.com/marcobambini/gravity>
- **上游文档:** <https://www.gravity-lang.org/>
- **许可证:** MIT
- **源码归档:** <https://github.com/marcobambini/gravity/archive/refs/tags/0.9.7.tar.gz>
- **最后更新:** 2026-04-14T22:07:19Z
- **已生成:** 2026-07-08T07:18:31+00:00

## 可执行文件

- gravity (cli)
- gravity (别名)

## 安装行为

- post-install 钩子: 未定义
- Bottle: 可用 于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## 版本和新鲜度

- 页面生成时间: 2026-07-08
- 管理器版本: 0.9.7
- 管理器更新时间: 2026-04-14
- 本地数据: OK
- 上游仓库: https://github.com/marcobambini/gravity
- 检测到的最新版本: 0.9.7 (当前)
## 项目历史与用法

Gravity is an embeddable, dynamically typed programming language implemented in C. It is packaged as a command-line interpreter/runtime but is historically most important as a small VM designed to be embedded in applications.

### 项目历史

The official README says Gravity was developed from scratch for the Creo project to provide portable code across iOS and Android. It combines a class-based, concurrent scripting model with Swift-like syntax and a small native runtime.

The project site presents Gravity as a small high-performance language with no external dependencies and a VM intended to add little overhead to an application. The GitHub release series records continuing maintenance of the interpreter and runtime.

### 采用历史

Gravity's adoption is specialized rather than ecosystem-wide. The official README names Creo as a core embedding target and the Untold game engine as another use case.

In package-manager terms, Gravity appeals to developers who want a lightweight scripting language or a studyable bytecode VM without pulling in a large external runtime.

### 使用方式

Users can run the Gravity executable for scripts or embed the language in a C/C++ application. Its documented language model supports procedural, object-oriented, functional, data-driven, and prototype-style programming patterns.

The lack of external dependencies is part of the intended deployment story: package managers can build a small C runtime, while embedders can include the VM in an application.

### 为什么软件包爱好者会关心

Gravity is interesting to package nerds because it is a compact language runtime rather than a mainstream language ecosystem. It packages cleanly as a native executable while also serving as embeddable infrastructure.

It is also a useful comparison point with Lua, Wren, Squirrel, and other application scripting languages: the package is less about global ecosystem adoption and more about how easily a host application can carry a scripting VM.

### 时间线

- 2013: Marco Bambini's site associates Gravity with work beginning in 2013.
- 2018: Public attention around the Gravity site and repository highlighted the embeddable VM design.
- 2020: The maintainer opened GitHub Discussions for project questions and community discussion.
- 2026: The GitHub release page records 0.9.x maintenance releases with runtime and compiler fixes.

### Related projects

- Creo: the official README describes Gravity as the core language built into Creo.
- Untold game engine: the official README names Gravity as its scripting language.
- Lua, Wren, and Squirrel are comparable embeddable scripting-language package niches, though they are separate projects.

### 来源

- <https://creolabs.com/gravity>
- <https://github.com/marcobambini/gravity>
- <https://github.com/marcobambini/gravity/releases>
- <https://www.gravity-lang.org/>


## 安全说明

generalized runtime or code generation signal.

- **Geiger 风险:** yellow / 中
- generalized runtime or code generation signal

## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** gravity
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## 其他软件包管理器记录

- MacPorts - gravity: normalized package name match | MacPorts ports tree: lang/gravity/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## 相关链接

- [Secret-risk packages](https://www.automicvault.com/zh-hans/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/zh-hans/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Language runtime packages](https://www.automicvault.com/zh-hans/pkg/language-runtime-packages/) - Matched language runtime, compiler, or interpreter metadata.
- [Networking and protocol packages](https://www.automicvault.com/zh-hans/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [snobol4](https://www.automicvault.com/zh-hans/pkg/brew/snobol4/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, programming-language, runtime.
- [algol68g](https://www.automicvault.com/zh-hans/pkg/brew/algol68g/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, programming-language.
- [gnu-apl](https://www.automicvault.com/zh-hans/pkg/brew/gnu-apl/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, programming-language.
- [icon](https://www.automicvault.com/zh-hans/pkg/brew/icon/) - Shares av.db curated category or tags: cli, language-runtime, programming-language, runtime.
- [latino](https://www.automicvault.com/zh-hans/pkg/brew/latino/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, programming-language.
- [lua](https://www.automicvault.com/zh-hans/pkg/brew/lua/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, programming-language.
- [minimal-racket](https://www.automicvault.com/zh-hans/pkg/brew/minimal-racket/) - Shares av.db curated category or tags: cli, language-runtime, programming-language, runtime.
- [mosml](https://www.automicvault.com/zh-hans/pkg/brew/mosml/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, programming-language.

## Combined YAML source

View the package source record on GitHub. [combined/gravity.yml](https://github.com/automic-vault/db/blob/main/combined/gravity.yml)


## 来源

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
