From 7683b7f0a36aefaebdcc8c7624e253457791eb08 Mon Sep 17 00:00:00 2001 From: John Adler Date: Wed, 26 May 2021 19:22:37 -0400 Subject: [PATCH] Rename Fume -> Sway (#56) * Rename Fume -> Sway. * Alpha. --- Cargo.toml | 3 +-- README.md | 11 +++++------ docs/book.toml | 4 ++-- docs/src/README.md | 2 +- docs/src/SUMMARY.md | 2 +- example_project/example_dependency/Forc.toml | 2 +- .../example_dependency/src/{main.fm => main.sw} | 0 example_project/fuel_project/src/{main.fm => main.sw} | 0 forc/src/ops/forc_init.rs | 2 +- forc/src/utils/defaults.rs | 2 +- forc/src/utils/manifest.rs | 2 +- stdlib/src/{main.fm => main.sw} | 0 {fume-server => sway-server}/Cargo.toml | 4 +--- .../src/capabilities/completion.rs | 0 .../src/capabilities/diagnostic.rs | 0 .../src/capabilities/document_symbol.rs | 0 .../src/capabilities/go_to.rs | 0 .../src/capabilities/highlight.rs | 0 .../src/capabilities/hover.rs | 0 {fume-server => sway-server}/src/capabilities/mod.rs | 0 .../src/capabilities/semantic_tokens.rs | 0 .../src/capabilities/text_sync.rs | 0 {fume-server => sway-server}/src/core/document.rs | 0 {fume-server => sway-server}/src/core/mod.rs | 0 {fume-server => sway-server}/src/core/session.rs | 0 {fume-server => sway-server}/src/core/token.rs | 0 {fume-server => sway-server}/src/main.rs | 0 {fume-server => sway-server}/src/server.rs | 0 .../test_programs/script_1/Forc.toml | 2 +- .../test_programs/script_1/src/{main.fm => main.sw} | 0 .../test_programs/script_2/Forc.toml | 2 +- .../test_programs/script_2/src/{main.fm => main.sw} | 0 .../test_programs/script_3/Forc.toml | 2 +- .../test_programs/script_3/src/{main.fm => main.sw} | 0 34 files changed, 18 insertions(+), 22 deletions(-) rename example_project/example_dependency/src/{main.fm => main.sw} (100%) rename example_project/fuel_project/src/{main.fm => main.sw} (100%) rename stdlib/src/{main.fm => main.sw} (100%) rename {fume-server => sway-server}/Cargo.toml (75%) rename {fume-server => sway-server}/src/capabilities/completion.rs (100%) rename {fume-server => sway-server}/src/capabilities/diagnostic.rs (100%) rename {fume-server => sway-server}/src/capabilities/document_symbol.rs (100%) rename {fume-server => sway-server}/src/capabilities/go_to.rs (100%) rename {fume-server => sway-server}/src/capabilities/highlight.rs (100%) rename {fume-server => sway-server}/src/capabilities/hover.rs (100%) rename {fume-server => sway-server}/src/capabilities/mod.rs (100%) rename {fume-server => sway-server}/src/capabilities/semantic_tokens.rs (100%) rename {fume-server => sway-server}/src/capabilities/text_sync.rs (100%) rename {fume-server => sway-server}/src/core/document.rs (100%) rename {fume-server => sway-server}/src/core/mod.rs (100%) rename {fume-server => sway-server}/src/core/session.rs (100%) rename {fume-server => sway-server}/src/core/token.rs (100%) rename {fume-server => sway-server}/src/main.rs (100%) rename {fume-server => sway-server}/src/server.rs (100%) rename test_suite/src/basic_compilation_tests/test_programs/script_1/src/{main.fm => main.sw} (100%) rename test_suite/src/basic_compilation_tests/test_programs/script_2/src/{main.fm => main.sw} (100%) rename test_suite/src/basic_compilation_tests/test_programs/script_3/src/{main.fm => main.sw} (100%) diff --git a/Cargo.toml b/Cargo.toml index 466f1bcd430..008ec898705 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,4 +1,3 @@ [workspace] -members = ["core_lang", "forc", "test_suite", "fume-server"] - +members = ["core_lang", "forc", "sway-server", "test_suite"] diff --git a/README.md b/README.md index 1d0af8fb8e1..a8ff63303c2 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,13 @@ -# Fume +# Sway -Fume is a language developed for the Fuel blockchain. It is heavily inspired by Rust and aims to bring modern language development and performance to the blockchain ecosystem. +Sway is a language developed for the Fuel blockchain. It is heavily inspired by Rust and aims to bring modern language development and performance to the blockchain ecosystem. ## Running the Compiler -To run the compiler from this directory: -``` -cargo run --bin forc -- -p -// e.g. +To run the compiler from this directory: +```sh +cargo run --bin forc -- -p cargo run --bin forc -- build -p example_project/fuel_project ``` diff --git a/docs/book.toml b/docs/book.toml index 10b9222b587..9fa8e60ea66 100644 --- a/docs/book.toml +++ b/docs/book.toml @@ -3,10 +3,10 @@ authors = ["John Adler"] language = "en" multilingual = false src = "src" -title = "The Fume Programming Language" +title = "The Sway Programming Language" [output.html] -git-repository-url = "https://github.com/FuelLabs/fuel-vm-hll" +git-repository-url = "https://github.com/FuelLabs/sway" [rust] edition = "2018" diff --git a/docs/src/README.md b/docs/src/README.md index 9898f310849..bc03f58d6e4 100644 --- a/docs/src/README.md +++ b/docs/src/README.md @@ -1 +1 @@ -# The Fume Programming Language +# The Sway Programming Language diff --git a/docs/src/SUMMARY.md b/docs/src/SUMMARY.md index fc7863eb077..eb0ce30677d 100644 --- a/docs/src/SUMMARY.md +++ b/docs/src/SUMMARY.md @@ -1,6 +1,6 @@ # Summary -[The Fume Programming Language](./README.md) +[The Sway Programming Language](./README.md) - [Getting Started](./c01/README.md) - [Installation](./c01/s01.md) diff --git a/example_project/example_dependency/Forc.toml b/example_project/example_dependency/Forc.toml index 5eda2015894..7ea0ed6dfe8 100644 --- a/example_project/example_dependency/Forc.toml +++ b/example_project/example_dependency/Forc.toml @@ -2,7 +2,7 @@ author = "Alex Hansen" license = "MIT" name = "example_dependency" -entry = "main.fm" +entry = "main.sw" [dependencies] diff --git a/example_project/example_dependency/src/main.fm b/example_project/example_dependency/src/main.sw similarity index 100% rename from example_project/example_dependency/src/main.fm rename to example_project/example_dependency/src/main.sw diff --git a/example_project/fuel_project/src/main.fm b/example_project/fuel_project/src/main.sw similarity index 100% rename from example_project/fuel_project/src/main.fm rename to example_project/fuel_project/src/main.sw diff --git a/forc/src/ops/forc_init.rs b/forc/src/ops/forc_init.rs index 89b76876b40..3ee6d6f1605 100644 --- a/forc/src/ops/forc_init.rs +++ b/forc/src/ops/forc_init.rs @@ -13,7 +13,7 @@ pub(crate) fn init_new_project(project_name: String) -> Result<(), Box String { author = "{}" license = "MIT" name = "{}" -entry = "main.fm" +entry = "main.sw" [dependencies] diff --git a/forc/src/utils/manifest.rs b/forc/src/utils/manifest.rs index ef756377e9d..a7e6c9bb25c 100644 --- a/forc/src/utils/manifest.rs +++ b/forc/src/utils/manifest.rs @@ -22,7 +22,7 @@ pub struct Project { } fn default_entry() -> String { - "main.fm".into() + "main.sw".into() } #[derive(Deserialize, Debug)] diff --git a/stdlib/src/main.fm b/stdlib/src/main.sw similarity index 100% rename from stdlib/src/main.fm rename to stdlib/src/main.sw diff --git a/fume-server/Cargo.toml b/sway-server/Cargo.toml similarity index 75% rename from fume-server/Cargo.toml rename to sway-server/Cargo.toml index 59e30e84a2f..388607b1f43 100644 --- a/fume-server/Cargo.toml +++ b/sway-server/Cargo.toml @@ -1,11 +1,9 @@ [package] authors = ["leviathan88 "] edition = "2018" -name = "fume-server" +name = "sway-server" version = "0.1.0" -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html - [dependencies] core_lang = {path = "../core_lang"} dashmap = "4.0.2" diff --git a/fume-server/src/capabilities/completion.rs b/sway-server/src/capabilities/completion.rs similarity index 100% rename from fume-server/src/capabilities/completion.rs rename to sway-server/src/capabilities/completion.rs diff --git a/fume-server/src/capabilities/diagnostic.rs b/sway-server/src/capabilities/diagnostic.rs similarity index 100% rename from fume-server/src/capabilities/diagnostic.rs rename to sway-server/src/capabilities/diagnostic.rs diff --git a/fume-server/src/capabilities/document_symbol.rs b/sway-server/src/capabilities/document_symbol.rs similarity index 100% rename from fume-server/src/capabilities/document_symbol.rs rename to sway-server/src/capabilities/document_symbol.rs diff --git a/fume-server/src/capabilities/go_to.rs b/sway-server/src/capabilities/go_to.rs similarity index 100% rename from fume-server/src/capabilities/go_to.rs rename to sway-server/src/capabilities/go_to.rs diff --git a/fume-server/src/capabilities/highlight.rs b/sway-server/src/capabilities/highlight.rs similarity index 100% rename from fume-server/src/capabilities/highlight.rs rename to sway-server/src/capabilities/highlight.rs diff --git a/fume-server/src/capabilities/hover.rs b/sway-server/src/capabilities/hover.rs similarity index 100% rename from fume-server/src/capabilities/hover.rs rename to sway-server/src/capabilities/hover.rs diff --git a/fume-server/src/capabilities/mod.rs b/sway-server/src/capabilities/mod.rs similarity index 100% rename from fume-server/src/capabilities/mod.rs rename to sway-server/src/capabilities/mod.rs diff --git a/fume-server/src/capabilities/semantic_tokens.rs b/sway-server/src/capabilities/semantic_tokens.rs similarity index 100% rename from fume-server/src/capabilities/semantic_tokens.rs rename to sway-server/src/capabilities/semantic_tokens.rs diff --git a/fume-server/src/capabilities/text_sync.rs b/sway-server/src/capabilities/text_sync.rs similarity index 100% rename from fume-server/src/capabilities/text_sync.rs rename to sway-server/src/capabilities/text_sync.rs diff --git a/fume-server/src/core/document.rs b/sway-server/src/core/document.rs similarity index 100% rename from fume-server/src/core/document.rs rename to sway-server/src/core/document.rs diff --git a/fume-server/src/core/mod.rs b/sway-server/src/core/mod.rs similarity index 100% rename from fume-server/src/core/mod.rs rename to sway-server/src/core/mod.rs diff --git a/fume-server/src/core/session.rs b/sway-server/src/core/session.rs similarity index 100% rename from fume-server/src/core/session.rs rename to sway-server/src/core/session.rs diff --git a/fume-server/src/core/token.rs b/sway-server/src/core/token.rs similarity index 100% rename from fume-server/src/core/token.rs rename to sway-server/src/core/token.rs diff --git a/fume-server/src/main.rs b/sway-server/src/main.rs similarity index 100% rename from fume-server/src/main.rs rename to sway-server/src/main.rs diff --git a/fume-server/src/server.rs b/sway-server/src/server.rs similarity index 100% rename from fume-server/src/server.rs rename to sway-server/src/server.rs diff --git a/test_suite/src/basic_compilation_tests/test_programs/script_1/Forc.toml b/test_suite/src/basic_compilation_tests/test_programs/script_1/Forc.toml index e2d079acf68..d9c16b43ac1 100644 --- a/test_suite/src/basic_compilation_tests/test_programs/script_1/Forc.toml +++ b/test_suite/src/basic_compilation_tests/test_programs/script_1/Forc.toml @@ -2,7 +2,7 @@ author = "Alexander Hansen " license = "MIT" name = "script_1" -entry = "main.fm" +entry = "main.sw" [dependencies] diff --git a/test_suite/src/basic_compilation_tests/test_programs/script_1/src/main.fm b/test_suite/src/basic_compilation_tests/test_programs/script_1/src/main.sw similarity index 100% rename from test_suite/src/basic_compilation_tests/test_programs/script_1/src/main.fm rename to test_suite/src/basic_compilation_tests/test_programs/script_1/src/main.sw diff --git a/test_suite/src/basic_compilation_tests/test_programs/script_2/Forc.toml b/test_suite/src/basic_compilation_tests/test_programs/script_2/Forc.toml index e2d079acf68..d9c16b43ac1 100644 --- a/test_suite/src/basic_compilation_tests/test_programs/script_2/Forc.toml +++ b/test_suite/src/basic_compilation_tests/test_programs/script_2/Forc.toml @@ -2,7 +2,7 @@ author = "Alexander Hansen " license = "MIT" name = "script_1" -entry = "main.fm" +entry = "main.sw" [dependencies] diff --git a/test_suite/src/basic_compilation_tests/test_programs/script_2/src/main.fm b/test_suite/src/basic_compilation_tests/test_programs/script_2/src/main.sw similarity index 100% rename from test_suite/src/basic_compilation_tests/test_programs/script_2/src/main.fm rename to test_suite/src/basic_compilation_tests/test_programs/script_2/src/main.sw diff --git a/test_suite/src/basic_compilation_tests/test_programs/script_3/Forc.toml b/test_suite/src/basic_compilation_tests/test_programs/script_3/Forc.toml index e2d079acf68..d9c16b43ac1 100644 --- a/test_suite/src/basic_compilation_tests/test_programs/script_3/Forc.toml +++ b/test_suite/src/basic_compilation_tests/test_programs/script_3/Forc.toml @@ -2,7 +2,7 @@ author = "Alexander Hansen " license = "MIT" name = "script_1" -entry = "main.fm" +entry = "main.sw" [dependencies] diff --git a/test_suite/src/basic_compilation_tests/test_programs/script_3/src/main.fm b/test_suite/src/basic_compilation_tests/test_programs/script_3/src/main.sw similarity index 100% rename from test_suite/src/basic_compilation_tests/test_programs/script_3/src/main.fm rename to test_suite/src/basic_compilation_tests/test_programs/script_3/src/main.sw