mirror of
https://github.com/roc-lang/roc.git
synced 2025-11-03 06:02:54 +00:00
moved all crates into seperate folder + related path fixes
This commit is contained in:
parent
12ef03bb86
commit
eee85fa45d
1063 changed files with 92 additions and 93 deletions
108
Cargo.toml
108
Cargo.toml
|
|
@ -1,56 +1,56 @@
|
||||||
[workspace]
|
[workspace]
|
||||||
members = [
|
members = [
|
||||||
"compiler/ident",
|
"crates/compiler/ident",
|
||||||
"compiler/region",
|
"crates/compiler/region",
|
||||||
"compiler/collections",
|
"crates/compiler/collections",
|
||||||
"compiler/exhaustive",
|
"crates/compiler/exhaustive",
|
||||||
"compiler/module",
|
"crates/compiler/module",
|
||||||
"compiler/parse",
|
"crates/compiler/parse",
|
||||||
"compiler/can",
|
"crates/compiler/can",
|
||||||
"compiler/problem",
|
"crates/compiler/problem",
|
||||||
"compiler/types",
|
"crates/compiler/types",
|
||||||
"compiler/builtins",
|
"crates/compiler/builtins",
|
||||||
"compiler/constrain",
|
"crates/compiler/constrain",
|
||||||
"compiler/unify",
|
"crates/compiler/unify",
|
||||||
"compiler/solve",
|
"crates/compiler/solve",
|
||||||
"compiler/late_solve",
|
"crates/compiler/late_solve",
|
||||||
"compiler/fmt",
|
"crates/compiler/fmt",
|
||||||
"compiler/derive_key",
|
"crates/compiler/derive_key",
|
||||||
"compiler/mono",
|
"crates/compiler/mono",
|
||||||
"compiler/alias_analysis",
|
"crates/compiler/alias_analysis",
|
||||||
"compiler/test_mono",
|
"crates/compiler/test_mono",
|
||||||
"compiler/test_derive",
|
"crates/compiler/test_derive",
|
||||||
"compiler/load",
|
"crates/compiler/load",
|
||||||
"compiler/load_internal",
|
"crates/compiler/load_internal",
|
||||||
"compiler/gen_llvm",
|
"crates/compiler/gen_llvm",
|
||||||
"compiler/gen_dev",
|
"crates/compiler/gen_dev",
|
||||||
"compiler/gen_wasm",
|
"crates/compiler/gen_wasm",
|
||||||
"compiler/build",
|
"crates/compiler/build",
|
||||||
"compiler/arena_pool",
|
"crates/compiler/arena_pool",
|
||||||
"compiler/test_gen",
|
"crates/compiler/test_gen",
|
||||||
"compiler/roc_target",
|
"crates/compiler/roc_target",
|
||||||
"compiler/debug_flags",
|
"crates/compiler/debug_flags",
|
||||||
"vendor/inkwell",
|
"crates/vendor/inkwell",
|
||||||
"vendor/pathfinding",
|
"crates/vendor/pathfinding",
|
||||||
"vendor/pretty",
|
"crates/vendor/pretty",
|
||||||
"bindgen",
|
"crates/bindgen",
|
||||||
"editor",
|
"crates/editor",
|
||||||
"ast",
|
"crates/ast",
|
||||||
"cli",
|
"crates/cli",
|
||||||
"code_markup",
|
"crates/code_markup",
|
||||||
"highlight",
|
"crates/highlight",
|
||||||
"error_macros",
|
"crates/error_macros",
|
||||||
"reporting",
|
"crates/reporting",
|
||||||
"repl_cli",
|
"crates/repl_cli",
|
||||||
"repl_eval",
|
"crates/repl_eval",
|
||||||
"repl_test",
|
"crates/repl_test",
|
||||||
"repl_wasm",
|
"crates/repl_wasm",
|
||||||
"test_utils",
|
"crates/test_utils",
|
||||||
"utils",
|
"crates/utils",
|
||||||
"docs",
|
"crates/docs",
|
||||||
"docs_cli",
|
"crates/docs_cli",
|
||||||
"linker",
|
"crates/linker",
|
||||||
"wasi-libc-sys",
|
"crates/wasi-libc-sys",
|
||||||
]
|
]
|
||||||
exclude = [
|
exclude = [
|
||||||
# Examples sometimes have Rust hosts in their platforms. The compiler should ignore those.
|
# Examples sometimes have Rust hosts in their platforms. The compiler should ignore those.
|
||||||
|
|
@ -58,10 +58,10 @@ exclude = [
|
||||||
"ci/bench-runner",
|
"ci/bench-runner",
|
||||||
# Ignore building these normally. They are only imported by tests.
|
# Ignore building these normally. They are only imported by tests.
|
||||||
# The tests will still correctly build them.
|
# The tests will still correctly build them.
|
||||||
"cli_utils",
|
"crates/cli_utils",
|
||||||
"compiler/test_mono_macros",
|
"crates/compiler/test_mono_macros",
|
||||||
# `cargo build` would cause roc_std to be built with default features which errors on windows
|
# `cargo build` would cause roc_std to be built with default features which errors on windows
|
||||||
"roc_std",
|
"crates/roc_std",
|
||||||
]
|
]
|
||||||
# Needed to be able to run `cargo run -p roc_cli --no-default-features` -
|
# Needed to be able to run `cargo run -p roc_cli --no-default-features` -
|
||||||
# see www/build.sh for more.
|
# see www/build.sh for more.
|
||||||
|
|
|
||||||
|
|
@ -1 +0,0 @@
|
||||||
../../../examples/interactive/cli-platform
|
|
||||||
|
|
@ -48,6 +48,7 @@ pub fn fixtures_dir(dir_name: &str) -> PathBuf {
|
||||||
let mut path = root_dir();
|
let mut path = root_dir();
|
||||||
|
|
||||||
// Descend into cli/tests/fixtures/{dir_name}
|
// Descend into cli/tests/fixtures/{dir_name}
|
||||||
|
path.push("crates");
|
||||||
path.push("bindgen");
|
path.push("bindgen");
|
||||||
path.push("tests");
|
path.push("tests");
|
||||||
path.push("fixtures");
|
path.push("fixtures");
|
||||||
|
|
@ -34,7 +34,7 @@ mod bindgen_cli_run {
|
||||||
|
|
||||||
let output = Command::new("cargo")
|
let output = Command::new("cargo")
|
||||||
.args(args)
|
.args(args)
|
||||||
.current_dir(root_dir().join("cli"))
|
.current_dir(root_dir().join("crates").join("cli"))
|
||||||
.output()
|
.output()
|
||||||
.unwrap_or_else(|err| {
|
.unwrap_or_else(|err| {
|
||||||
panic!(
|
panic!(
|
||||||
|
|
@ -178,6 +178,7 @@ mod bindgen_cli_run {
|
||||||
.parent()
|
.parent()
|
||||||
.unwrap()
|
.unwrap()
|
||||||
.join("fixture-templates");
|
.join("fixture-templates");
|
||||||
|
dbg!(&fixture_templates_dir);
|
||||||
|
|
||||||
// Copy the rust template from the templates directory into the fixture dir.
|
// Copy the rust template from the templates directory into the fixture dir.
|
||||||
dircpy::CopyBuilder::new(fixture_templates_dir.join("rust"), platform_dir)
|
dircpy::CopyBuilder::new(fixture_templates_dir.join("rust"), platform_dir)
|
||||||
|
|
@ -53,7 +53,7 @@ pub const ROC_DIR: &str = "ROC_DIR";
|
||||||
pub const DIRECTORY_OR_FILES: &str = "DIRECTORY_OR_FILES";
|
pub const DIRECTORY_OR_FILES: &str = "DIRECTORY_OR_FILES";
|
||||||
pub const ARGS_FOR_APP: &str = "ARGS_FOR_APP";
|
pub const ARGS_FOR_APP: &str = "ARGS_FOR_APP";
|
||||||
|
|
||||||
const VERSION: &str = include_str!("../../version.txt");
|
const VERSION: &str = include_str!("../../../version.txt");
|
||||||
|
|
||||||
pub fn build_app<'a>() -> Command<'a> {
|
pub fn build_app<'a>() -> Command<'a> {
|
||||||
let flag_optimize = Arg::new(FLAG_OPTIMIZE)
|
let flag_optimize = Arg::new(FLAG_OPTIMIZE)
|
||||||
|
|
@ -241,7 +241,10 @@ fn main() -> io::Result<()> {
|
||||||
Ok(format_exit_code)
|
Ok(format_exit_code)
|
||||||
}
|
}
|
||||||
Some((CMD_VERSION, _)) => {
|
Some((CMD_VERSION, _)) => {
|
||||||
print!("{}", concatcp!("roc ", include_str!("../../version.txt")));
|
print!(
|
||||||
|
"{}",
|
||||||
|
concatcp!("roc ", include_str!("../../../version.txt"))
|
||||||
|
);
|
||||||
|
|
||||||
Ok(0)
|
Ok(0)
|
||||||
}
|
}
|
||||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue