登录 注册
开发者工具 compilerfuellanguagesway
61,338
Stars
5,430
Forks
296
Watchers
962
Open Issues
Apache-2.0
许可证
Rust
语言
2021-01-19
创建时间
2026-11-10
最近更新

项目能做什么

助力开发者构建可靠且高效智能合约的工具与语言。
来源:基于仓库元数据 · 内容以仓库实际 README 为准

使用说明 查看原始 README 原仓库文档

中文使用说明暂未生成。下面保留原仓库 README 摘录,命令与配置均以原文为准。
原始 README 摘录(英文原文,节选前 3000 字符)
# Sway

[![build](https://github.com/FuelLabs/sway/actions/workflows/ci.yml/badge.svg)](https://github.com/FuelLabs/sway/actions/workflows/ci.yml)
[![crates.io](https://img.shields.io/crates/v/forc?label=latest)](https://crates.io/crates/forc)
[![docs](https://docs.rs/forc/badge.svg)](https://docs.rs/forc/)
[![twitter](https://img.shields.io/twitter/follow/SwayLang)](https://x.com/SwayLang)
[![discord](https://img.shields.io/badge/chat%20on-discord-orange?&logo=discord&logoColor=ffffff&color=7389D8&labelColor=6A7EC2)](https://discord.gg/xfpK4Pe)

Sway is a language developed for the [Fuel](https://docs.fuel.network/docs/intro/what-is-fuel/) blockchain. It is heavily inspired by Rust and aims to bring modern language development and performance to the blockchain ecosystem.

## Documentation

For user documentation, including installing release builds, see the latest released Sway Book: <https://fuellabs.github.io/sway/latest/>.

The documentation URLs describe different source versions:

- `latest` redirects to the most recently published Sway release.
- `vX.Y.Z` is documentation built from that exact Sway release tag.
- `master` is built from the default branch and may describe unreleased behavior.

These labels are Sway documentation versions. They are not Fuelup channel names and do not identify the toolchain activated on a Fuel network. Check the compiler you are running with `forc --version` and consult the [Fuelup channel documentation](https://install.fuel.network/master/concepts/channels.html) when selecting network-compatible tooling.

For Sway standard library documentation from the default branch, see <https://fuellabs.github.io/sway/master/std/>.

Also view the default-branch technical reference for the Sway programming language at <https://fuellabs.github.io/sway/master/reference/>.

The **Stable** Sway and Forc pages on `docs.fuel.network` are published by [`FuelLabs/docs-hub`](https://github.com/FuelLabs/docs-hub) from an explicitly selected Sway release. That selection can differ from both the newest upstream release and the compiler in a named Fuelup network channel.

## Building from Source

This section is for developing the Sway compiler and toolchain. For developing contracts and using Sway, see the above documentation section.

### Dependencies

Sway is built in Rust. To begin, install the Rust toolchain following instructions at <https://www.rust-lang.org/tools/install>. Then configure your Rust toolchain to use Rust `stable`:

```sh
rustup default stable
```

If not already done, add the Cargo bin directory to your `PATH` by adding the following line to `~/.profile` and restarting the shell session.

```sh
export PATH="${HOME}/.cargo/bin:${PATH}"
```

### Building Forc

Clone the repository and build the Sway toolchain:

```sh
git clone git@github.com:FuelLabs/sway.git
cd sway
cargo build
```

Confirm the Sway toolchain built successfully:

```sh
cargo run --bin forc -- --help
```

## All other scripts/commands

For all oth
阅读完整原文

项目深度分析 规则生成(AI 未配置)

综合评分 37.5 分。该项目在“个人可实施性”维度得 35 分,“付费可能性”维度得 20.0 分,差异化空间 40.0 分(评分依据见评分卡)。

面向细分需求的二次开发产品

产品构想基于 sway 的核心能力,聚焦一个更窄的场景(如某平台、某行业)做差异化。
目标用户该细分场景用户
难度/周期中 · 2~6 周
收费模式买断制 / 订阅制 / 广告
竞争风险细分需求规模需验证
依据 AI 推测:基于项目主题标签的判断
以上为规则引擎基于仓库公开数据生成的参考结论,包含推测成分,不构成投资或创业承诺;配置 AI 后可获得更深入的分析。
报告会保存到 个人中心

竞品与相似项目 GitHub Search 真实检索

相似项目数据正在完善中,暂不展示(避免误导)

项目优势与风险

技术成熟度创建于 2021-01-19,近 30 天仍在推送,发布过 100 个 Release
社区活跃Star 61,338 / Fork 5,430 / Issue 962(数据支持,可自行核实)
许可证Apache-2.0
主要风险上游项目方向可能变化;同赛道竞争者较多(见竞品表);热度与需求不完全等价

安装与使用

此项目未提供 Docker 镜像,安装步骤以原仓库 README 为准(涉及依赖安装与环境配置,对新手门槛较高)。