From abdc8fce93217fa35284cde9e17c5cebbe429576 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 19:28:11 -0800 Subject: [PATCH 01/21] cargo fmt fixes --- create-rust-app_cli/qsync/src/hook.rs | 27 +++++++++++++--------- create-rust-app_cli/qsync/src/lib.rs | 4 ++-- create-rust-app_cli/qsync/src/processor.rs | 23 ++++++++++-------- create-rust-app_cli/src/main.rs | 2 +- 4 files changed, 33 insertions(+), 23 deletions(-) diff --git a/create-rust-app_cli/qsync/src/hook.rs b/create-rust-app_cli/qsync/src/hook.rs index 7d2f73cd..a719846a 100644 --- a/create-rust-app_cli/qsync/src/hook.rs +++ b/create-rust-app_cli/qsync/src/hook.rs @@ -1,5 +1,4 @@ use std::fmt::Write as _; -use crate::utils; use super::params::is_primitive_type; use super::processor::HttpVerb; @@ -203,7 +202,7 @@ impl Hook { } } - if (/* !self.path_params.is_empty() || */ !self.query_params.is_empty()) + if (/* !self.path_params.is_empty() || */!self.query_params.is_empty()) && !self.body_params.is_empty() { query_key.push_str(", "); @@ -223,15 +222,21 @@ impl Hook { query_key.insert_str(0, ", ") } - let query_key_base = self.endpoint_url.trim_start_matches("/api/").split("/").into_iter().map(|t| { - // in actix-web, paths which have {} denote a path param - if t.starts_with("{") && t.ends_with("}") { - let path_param = t.chars().skip(1).take(t.len() - 2).collect::(); - format!("pathParams.{path_param}") - } else { - format!("\"{t}\"").to_string() - } - }).collect::>(); + let query_key_base = self + .endpoint_url + .trim_start_matches("/api/") + .split("/") + .into_iter() + .map(|t| { + // in actix-web, paths which have {} denote a path param + if t.starts_with("{") && t.ends_with("}") { + let path_param = t.chars().skip(1).take(t.len() - 2).collect::(); + format!("pathParams.{path_param}") + } else { + format!("\"{t}\"").to_string() + } + }) + .collect::>(); query_key.insert_str(0, &format!("{}", query_key_base.join(", "))); diff --git a/create-rust-app_cli/qsync/src/lib.rs b/create-rust-app_cli/qsync/src/lib.rs index 2905e537..d1fc19e8 100644 --- a/create-rust-app_cli/qsync/src/lib.rs +++ b/create-rust-app_cli/qsync/src/lib.rs @@ -1,10 +1,10 @@ extern crate syn; -mod utils; mod hook; mod params; mod processor; +mod utils; pub use processor::process; /// the #[qsync] attribute macro which marks structs and types to be translated into queries -pub use qsync_macro::qsync; \ No newline at end of file +pub use qsync_macro::qsync; diff --git a/create-rust-app_cli/qsync/src/processor.rs b/create-rust-app_cli/qsync/src/processor.rs index 29bc12f5..63d25a62 100644 --- a/create-rust-app_cli/qsync/src/processor.rs +++ b/create-rust-app_cli/qsync/src/processor.rs @@ -1,13 +1,14 @@ use super::hook::{Hook, HookBodyParam, HookPathParam, HookQueryParam}; use super::params::generic_to_typsecript_type; +use darling::FromMeta; use regex::Regex; use std::fs::File; use std::io::Read; use std::io::Write; use std::path::Path; use std::path::PathBuf; -use darling::FromMeta; +use crate::utils::file_path_to_vec_string; use syn::FnArg; use syn::Pat; use syn::PatType; @@ -15,7 +16,6 @@ use syn::PathArguments; use syn::Type; use syn::TypePath; use walkdir::WalkDir; -use crate::utils::file_path_to_vec_string; extern crate inflector; use super::processor::inflector::Inflector; @@ -46,7 +46,10 @@ fn has_qsync_attribute( let meta = attr.parse_meta().unwrap(); // extract and compare against attribute's identifier (#[path::to::identifier]) - let attr_identifier = meta.path().segments.last() + let attr_identifier = meta + .path() + .segments + .last() .map(|r| r.ident.to_string()) .unwrap_or_default(); @@ -64,7 +67,9 @@ fn has_qsync_attribute( let args = args.unwrap(); qsync_props.is_mutation = args.mutate.unwrap_or_default(); - if args.return_type.is_some() { qsync_props.return_type = args.return_type.unwrap(); } + if args.return_type.is_some() { + qsync_props.return_type = args.return_type.unwrap(); + } } "get" => { has_actix_attribute = true; @@ -562,11 +567,11 @@ pub fn process(input_paths: Vec, output_path: PathBuf, is_debug: bool) // added, existing, &output_path // ) // } else { - let mut file: File = File::create(&output_path).expect("Unable to write to file"); - match file.write_all(state.types.as_bytes()) { - Ok(_) => println!("Successfully generated hooks, see {output_path:#?}"), - Err(_) => println!("Failed to generate types, an error occurred."), - } + let mut file: File = File::create(&output_path).expect("Unable to write to file"); + match file.write_all(state.types.as_bytes()) { + Ok(_) => println!("Successfully generated hooks, see {output_path:#?}"), + Err(_) => println!("Failed to generate types, an error occurred."), + } // } } diff --git a/create-rust-app_cli/src/main.rs b/create-rust-app_cli/src/main.rs index 5f6e724d..5e248edf 100644 --- a/create-rust-app_cli/src/main.rs +++ b/create-rust-app_cli/src/main.rs @@ -14,8 +14,8 @@ use std::path::PathBuf; use crate::project::CreationOptions; use content::project; use dialoguer::{console::Term, theme::ColorfulTheme, Input, MultiSelect, Select}; -use utils::{fs, logger}; use qsync; +use utils::{fs, logger}; #[derive(Clone, Copy, Debug, PartialEq, Eq, ValueEnum)] pub enum BackendFramework { From a5ab94bf4721f85ecfd167ff79d26fb02efe01b2 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 19:28:47 -0800 Subject: [PATCH 02/21] add initial CI --- .github/workflows/CLI-CI.yml | 54 ++++++++++++++++++++++++++++++++++++ Cargo.toml | 4 +-- 2 files changed, 56 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/CLI-CI.yml diff --git a/.github/workflows/CLI-CI.yml b/.github/workflows/CLI-CI.yml new file mode 100644 index 00000000..a746626b --- /dev/null +++ b/.github/workflows/CLI-CI.yml @@ -0,0 +1,54 @@ +name: CLI Continuous Integration (project compilation tests) +on: + workflow_dispatch: + push: + branches: + - "main" + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" + pull_request: + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" +env: + CARGO_TERM_COLOR: always + CARGO_INCREMENTAL: true + +concurrency: + group: CI-${{ github.ref }} + cancel-in-progress: true + +jobs: + # naming convention is: [backend]-[database]-[plugins] + Actix-Postgres-None: + name: Actix w/ Postgres and no plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + ./.cargo/.build + ./target + ~/.cargo + key: ${{ runner.os }}-cargo-cli-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: + cargo run --bin create-rust-app -- create -c -d postgres -b actix-web test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: + cargo fullstack + + diff --git a/Cargo.toml b/Cargo.toml index 914c3362..71597205 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,6 +2,6 @@ members = [ "create-rust-app", "create-rust-app_cli", - "create-rust-app_cli/qsync" + "create-rust-app_cli/qsync", ] -exclude = ["docs", "tests"] +exclude = ["docs", "tests", "test-project"] From 2d74af2c730353fcd420396c615ef3536c406470 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 19:36:41 -0800 Subject: [PATCH 03/21] clippy fixes --- .../src/dev/backend_compiling_server.rs | 51 +++++++++---------- create-rust-app_cli/qsync/src/hook.rs | 8 +-- create-rust-app_cli/src/main.rs | 2 +- 3 files changed, 28 insertions(+), 33 deletions(-) diff --git a/create-rust-app/src/dev/backend_compiling_server.rs b/create-rust-app/src/dev/backend_compiling_server.rs index 08901520..610e71ff 100644 --- a/create-rust-app/src/dev/backend_compiling_server.rs +++ b/create-rust-app/src/dev/backend_compiling_server.rs @@ -113,13 +113,12 @@ pub async fn start( let ws_s = dev_server_events_s.clone(); let migrations_dir = migrations_dir.clone(); async move { - let exit_events = action + // no exit events + if !action .events .iter() - .filter(|e| e.metadata.contains_key("exit-watchexec")) - .collect::>(); - - if !exit_events.is_empty() { + .any(|e| e.metadata.contains_key("exit-watchexec")) + { println!("continuous backend compilation stopped."); let mut m = state3.lock().await; m.watchexec_running = false; @@ -135,30 +134,26 @@ pub async fn start( // println!("=> ignoring {:#?}", files_to_ignore); let mut touched_migrations_dir = false; - let file_events = action - .events - .iter() - .filter(|e| { - e.tags.iter().any(|t| match t { - Tag::Path { path, file_type: _ } => { - if path - .to_str() - .unwrap() - .starts_with(migrations_dir.as_os_str().to_str().unwrap()) - { - touched_migrations_dir = true; - } - - !files_to_ignore.iter().any(|file_to_ignore| { - path.to_str().unwrap().ends_with(file_to_ignore) - }) + + // no file events + if !action.events.iter().any(|e| { + e.tags.iter().any(|t| match t { + Tag::Path { path, file_type: _ } => { + if path + .to_str() + .unwrap() + .starts_with(migrations_dir.as_os_str().to_str().unwrap()) + { + touched_migrations_dir = true; } - _ => false, - }) - }) - .collect::>(); - if !file_events.is_empty() { + !files_to_ignore + .iter() + .any(|file_to_ignore| path.to_str().unwrap().ends_with(file_to_ignore)) + } + _ => false, + }) + }) { // compile ws_s.send(DevServerEvent::BackendCompiling(true)).ok(); if compile(project_dir, ws_s.clone()) { @@ -249,7 +244,7 @@ fn compile(project_dir: &'static str, ws_s: Sender) -> bool { .duration_since(start_time) .map(|d| d.as_secs_f32()) .map(|d| format!("{d:.2}")) - .unwrap_or("?".to_string()); + .unwrap_or_else(|_| "?".to_string()); if finished.success { println!("✅ Compiled ({compile_time_s} seconds)"); diff --git a/create-rust-app_cli/qsync/src/hook.rs b/create-rust-app_cli/qsync/src/hook.rs index a719846a..7a38ebf9 100644 --- a/create-rust-app_cli/qsync/src/hook.rs +++ b/create-rust-app_cli/qsync/src/hook.rs @@ -225,20 +225,20 @@ impl Hook { let query_key_base = self .endpoint_url .trim_start_matches("/api/") - .split("/") + .split('/') .into_iter() .map(|t| { // in actix-web, paths which have {} denote a path param - if t.starts_with("{") && t.ends_with("}") { + if t.starts_with('{') && t.ends_with('}') { let path_param = t.chars().skip(1).take(t.len() - 2).collect::(); format!("pathParams.{path_param}") } else { - format!("\"{t}\"").to_string() + format!("\"{t}\"") } }) .collect::>(); - query_key.insert_str(0, &format!("{}", query_key_base.join(", "))); + query_key.insert_str(0, &query_key_base.join(", ")); query_key } diff --git a/create-rust-app_cli/src/main.rs b/create-rust-app_cli/src/main.rs index 5e248edf..a35b2c3f 100644 --- a/create-rust-app_cli/src/main.rs +++ b/create-rust-app_cli/src/main.rs @@ -14,7 +14,7 @@ use std::path::PathBuf; use crate::project::CreationOptions; use content::project; use dialoguer::{console::Term, theme::ColorfulTheme, Input, MultiSelect, Select}; -use qsync; + use utils::{fs, logger}; #[derive(Clone, Copy, Debug, PartialEq, Eq, ValueEnum)] From 263d1df8d4896e8d697d1ac8d6559fa425ab9f84 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 19:53:32 -0800 Subject: [PATCH 04/21] fix #141 remove references to dev plugin from cli, and fix some funky requirement shenanigans with the cli --- create-rust-app_cli/src/main.rs | 101 +++++++++++++++----------------- 1 file changed, 48 insertions(+), 53 deletions(-) diff --git a/create-rust-app_cli/src/main.rs b/create-rust-app_cli/src/main.rs index a35b2c3f..55d845d8 100644 --- a/create-rust-app_cli/src/main.rs +++ b/create-rust-app_cli/src/main.rs @@ -62,7 +62,6 @@ enum Commands { help = "Configure project through interactive CLI arguments.", requires = "database", requires = "backend framework", - requires = "plugins" )] cli_mode: bool, @@ -77,7 +76,6 @@ enum Commands { long="database", name="database", help="Database to use", - require_equals=true, value_name="DATABASE", value_parser=EnumValueParser::::new(), ignore_case=true, @@ -89,7 +87,6 @@ enum Commands { long="backend", name="backend framework", help="Rust backend framework to use", - require_equals=true, value_name="FRAMEWORK", value_parser=EnumValueParser::::new(), ignore_case=true, @@ -103,12 +100,10 @@ enum Commands { help="Plugins for your new project\nComma separated list ", num_args=1.., value_delimiter=',', - require_equals=true, value_name="PLUGINS", value_parser=[ PossibleValue::new("auth").help("Authentication Plugin: local email-based authentication"), PossibleValue::new("container").help("Container Plugin: dockerize your app"), - PossibleValue::new("dev").help("Development Plugin: adds dev warnings and an admin portal"), PossibleValue::new("storage").help("Storage Plugin: adds S3 file storage capabilities"), PossibleValue::new("graphql").help("GraphQL Plugin: bootstraps a GraphQL setup including a playground"), PossibleValue::new("utoipa").help("Utoipa Plugin: Autogenerated OpenAPI documentation served in a SwaggerUI playground"), @@ -291,7 +286,6 @@ fn create_project( .map(|plugin| match plugin.as_str() { "auth" => "plugin_auth".to_string(), "container" => "plugin_container".to_string(), - "dev" => "plugin_dev".to_string(), "storage" => "plugin_storage".to_string(), "graphql" => "plugin_graphql".to_string(), "utoipa" => "plugin_utoipa".to_string(), @@ -299,57 +293,58 @@ fn create_project( }) .collect(), None => { - if cli_mode { - panic!("Fatal: No plugins specified") - } - logger::message("Please select plugins for your new project:"); - logger::message( - "Use UP/DOWN arrows to navigate, SPACE to enable/disable a plugin, and ENTER to confirm.", - ); - - let items = vec![ - "Authentication Plugin: local email-based authentication", - "Container Plugin: dockerize your app", - // "Development Plugin: adds dev warnings and an admin portal", - "Storage Plugin: adds S3 file storage capabilities", - "GraphQL Plugin: bootstraps a GraphQL setup including a playground", - "Utoipa Plugin: Autogenerated OpenAPI documentation served in a SwaggerUI playground", - ]; - let chosen: Vec = MultiSelect::with_theme(&ColorfulTheme::default()) - .items(&items) - .defaults(&[true, true, true, true, false]) - .interact()?; - - let add_plugin_auth = chosen.iter().any(|x| *x == 0); - let add_plugin_container = chosen.iter().any(|x| *x == 1); - let add_plugin_dev = true; // chosen.iter().any(|x| *x == 2); - let add_plugin_storage = chosen.iter().any(|x| *x == 3); - let add_plugin_graphql = chosen.iter().any(|x| *x == 4); - let add_plugin_utoipa = chosen.iter().any(|x| *x == 5); - - let mut features: Vec = vec![]; - if add_plugin_auth { - features.push("plugin_auth".to_string()); - } - if add_plugin_container { - features.push("plugin_container".to_string()); - } - if add_plugin_dev { - features.push("plugin_dev".to_string()); - } - if add_plugin_storage { - features.push("plugin_storage".to_string()); - } - if add_plugin_graphql { - features.push("plugin_graphql".to_string()); + if !cli_mode { + logger::message("Please select plugins for your new project:"); + logger::message( + "Use UP/DOWN arrows to navigate, SPACE to enable/disable a plugin, and ENTER to confirm.", + ); + + let items = vec![ + "Authentication Plugin: local email-based authentication", + "Container Plugin: dockerize your app", + // "Development Plugin: adds dev warnings and an admin portal", + "Storage Plugin: adds S3 file storage capabilities", + "GraphQL Plugin: bootstraps a GraphQL setup including a playground", + "Utoipa Plugin: Autogenerated OpenAPI documentation served in a SwaggerUI playground", + ]; + let chosen: Vec = MultiSelect::with_theme(&ColorfulTheme::default()) + .items(&items) + .defaults(&[true, true, true, true, false]) + .interact()?; + + let add_plugin_auth = chosen.iter().any(|x| *x == 0); + let add_plugin_container = chosen.iter().any(|x| *x == 1); + let add_plugin_storage = chosen.iter().any(|x| *x == 3); + let add_plugin_graphql = chosen.iter().any(|x| *x == 4); + let add_plugin_utoipa = chosen.iter().any(|x| *x == 5); + + let mut features: Vec = vec![]; + if add_plugin_auth { + features.push("plugin_auth".to_string()); + } + if add_plugin_container { + features.push("plugin_container".to_string()); + } + if add_plugin_storage { + features.push("plugin_storage".to_string()); + } + if add_plugin_graphql { + features.push("plugin_graphql".to_string()); + } + if add_plugin_utoipa { + features.push("plugin_utoipa".to_string()); + } + + features } - if add_plugin_utoipa { - features.push("plugin_utoipa".to_string()); + else { + vec![] } - - features } }; + //add the dev plugin + cra_enabled_features.push("plugin_dev".to_string()); + // add database and framework to enabled features cra_enabled_features.push(match backend_database { BackendDatabase::Postgres => "database_postgres".to_string(), From a24afe69e63fd33bee9624b92884aa1f555e49ff Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:09:11 -0800 Subject: [PATCH 05/21] tests for each combination of backend and database --- .../{CLI-CI.yml => CLI-ActixPostgres-CI.yml} | 15 ++---- .github/workflows/CLI-ActixSqlite-CI.yml | 50 +++++++++++++++++++ .github/workflows/CLI-PoemPostgres-CI.yml | 49 ++++++++++++++++++ .github/workflows/CLI-PoemSqlite-CI.yml | 49 ++++++++++++++++++ 4 files changed, 153 insertions(+), 10 deletions(-) rename .github/workflows/{CLI-CI.yml => CLI-ActixPostgres-CI.yml} (74%) create mode 100644 .github/workflows/CLI-ActixSqlite-CI.yml create mode 100644 .github/workflows/CLI-PoemPostgres-CI.yml create mode 100644 .github/workflows/CLI-PoemSqlite-CI.yml diff --git a/.github/workflows/CLI-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml similarity index 74% rename from .github/workflows/CLI-CI.yml rename to .github/workflows/CLI-ActixPostgres-CI.yml index a746626b..f4590b83 100644 --- a/.github/workflows/CLI-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -15,7 +15,6 @@ on: - "Cargo.toml" env: CARGO_TERM_COLOR: always - CARGO_INCREMENTAL: true concurrency: group: CI-${{ github.ref }} @@ -37,18 +36,14 @@ jobs: - uses: actions/cache@v3.2.5 with: path: | - ./.cargo/.build - ./target - ~/.cargo - key: ${{ runner.os }}-cargo-cli-${{ hashFiles('**/Cargo.lock') }} + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: - cargo run --bin create-rust-app -- create -c -d postgres -b actix-web test-project + command: run --bin create-rust-app -- create -c -d postgres -b actix-web test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: - command: - cargo fullstack - + command: build diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml new file mode 100644 index 00000000..15121cd6 --- /dev/null +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -0,0 +1,50 @@ +name: CLI Continuous Integration (project compilation tests) +on: + workflow_dispatch: + push: + branches: + - "main" + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" + pull_request: + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" +env: + CARGO_TERM_COLOR: always + +concurrency: + group: CI-${{ github.ref }} + cancel-in-progress: true + +jobs: + # naming convention is: [backend]-[database]-[plugins] + Actix-Sqlite-None: + name: Actix w/ Sqlite and no plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: + cargo run --bin create-rust-app -- create -c -d sqlite -b actix-web test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: + cargo build diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml new file mode 100644 index 00000000..48b9675f --- /dev/null +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -0,0 +1,49 @@ +name: CLI Continuous Integration (project compilation tests) +on: + workflow_dispatch: + push: + branches: + - "main" + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" + pull_request: + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" +env: + CARGO_TERM_COLOR: always + +concurrency: + group: CI-${{ github.ref }} + cancel-in-progress: true + +jobs: + # naming convention is: [backend]-[database]-[plugins] + Poem-Postgres-None: + name: Poem w/ Postgres and no plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b poem test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + \ No newline at end of file diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml new file mode 100644 index 00000000..335bac62 --- /dev/null +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -0,0 +1,49 @@ +name: CLI Continuous Integration (project compilation tests) +on: + workflow_dispatch: + push: + branches: + - "main" + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" + pull_request: + paths: + - "**.rs" + - "Cargo.lock" + - "Cargo.toml" +env: + CARGO_TERM_COLOR: always + +concurrency: + group: CI-${{ github.ref }} + cancel-in-progress: true + +jobs: + # naming convention is: [backend]-[database]-[plugins] + Poem-Sqlite-None: + name: Poem w/ Sqlite and no plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b poem test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + From a2603cf7763b184234f72aa4ec53c4dfdf90c1e1 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:16:24 -0800 Subject: [PATCH 06/21] finish scenarios for Actix + Postgres currently only tests no plugins, all plugins, and each individual plugin not every combination --- .github/workflows/CLI-ActixPostgres-CI.yml | 155 +++++++++++++++++++++ 1 file changed, 155 insertions(+) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index f4590b83..f52f5278 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -47,3 +47,158 @@ jobs: with: command: build + Actix-Postgres-All: + needs: [Actix-Postgres-None] + name: Actix w/ Postgres and all valid plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Postgres-Container: + needs: [Actix-Postgres-None] + name: Actix w/ Postgres and the container plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=container test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Postgres-Auth: + needs: [Actix-Postgres-None] + name: Actix w/ Postgres and the auth plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Postgres-Storage: + needs: [Actix-Postgres-None] + name: Actix w/ Postgres and the storage plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=storage test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Postgres-GraphQL: + needs: [Actix-Postgres-None] + name: Actix w/ Postgres and the graphql plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=graphql test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Postgres-Utoipa: + needs: [Actix-Postgres-None] + name: Actix w/ Postgres and the utoipa plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,utoipa test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build \ No newline at end of file From eda6184e048b3dbf0f9ecf485224b674cddfae79 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:19:23 -0800 Subject: [PATCH 07/21] finish scenarios for Actix + Sqlite --- .github/workflows/CLI-ActixSqlite-CI.yml | 156 +++++++++++++++++++++++ 1 file changed, 156 insertions(+) diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 15121cd6..0448820f 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -48,3 +48,159 @@ jobs: with: command: cargo build + + Actix-Sqlite-All: + needs: [Actix-Sqlite-None] + name: Actix w/ Sqlite and all valid plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Sqlite-Container: + needs: [Actix-Sqlite-None] + name: Actix w/ Sqlite and the container plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=container test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Sqlite-Auth: + needs: [Actix-Sqlite-None] + name: Actix w/ Sqlite and the auth plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Sqlite-Storage: + needs: [Actix-Sqlite-None] + name: Actix w/ Sqlite and the storage plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=storage test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Sqlite-GraphQL: + needs: [Actix-Sqlite-None] + name: Actix w/ Sqlite and the graphql plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=graphql test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Actix-Sqlite-Utoipa: + needs: [Actix-Sqlite-None] + name: Actix w/ Sqlite and the utoipa plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,utoipa test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build \ No newline at end of file From 9b1776dadc108a2020363fec85744f259f089bf9 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:22:11 -0800 Subject: [PATCH 08/21] finish scenarios for Poem + Sqlite --- .github/workflows/CLI-PoemSqlite-CI.yml | 130 ++++++++++++++++++++++++ 1 file changed, 130 insertions(+) diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index 335bac62..39a6dc7b 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -47,3 +47,133 @@ jobs: with: command: build + + Poem-Sqlite-All: + needs: [Poem-Sqlite-None] + name: Poem w/ Sqlite and all valid plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth,container,graphql,storage test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Sqlite-Container: + needs: [Poem-Sqlite-None] + name: Poem w/ Sqlite and the container plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=container test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Sqlite-Auth: + needs: [Poem-Sqlite-None] + name: Poem w/ Sqlite and the auth plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Sqlite-Storage: + needs: [Poem-Sqlite-None] + name: Poem w/ Sqlite and the storage plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=storage test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Sqlite-GraphQL: + needs: [Poem-Sqlite-None] + name: Poem w/ Sqlite and the graphql plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=graphql test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build From f20145948b71082f435d4a96fefec28273498458 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:23:33 -0800 Subject: [PATCH 09/21] finish scenarios for Poem + Postgres --- .github/workflows/CLI-PoemPostgres-CI.yml | 131 +++++++++++++++++++++- 1 file changed, 130 insertions(+), 1 deletion(-) diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index 48b9675f..83bc61d7 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -46,4 +46,133 @@ jobs: - uses: actions-rs/cargo@v1.0.3 with: command: build - \ No newline at end of file + + Poem-Postgres-All: + needs: [Poem-Postgres-None] + name: Poem w/ Postgres and all valid plugins + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth,container,graphql,storage test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Postgres-Container: + needs: [Poem-Postgres-None] + name: Poem w/ Postgres and the container plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=container test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Postgres-Auth: + needs: [Poem-Postgres-None] + name: Poem w/ Postgres and the auth plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Postgres-Storage: + needs: [Poem-Postgres-None] + name: Poem w/ Postgres and the storage plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=storage test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build + + Poem-Postgres-GraphQL: + needs: [Poem-Postgres-None] + name: Poem w/ Postgres and the graphql plugin + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3.3.0 + - uses: rui314/setup-mold@v1 + - uses: actions-rs/toolchain@v1.0.7 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions/cache@v3.2.5 + with: + path: | + **/.cargo/.build + **/target + key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - uses: actions-rs/cargo@v1.0.3 + with: + command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=graphql test-project + - run: cd test-project + - uses: actions-rs/cargo@v1.0.3 + with: + command: build From 49d7adae27b95281121fe0438c7ba48626f7b46a Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:25:01 -0800 Subject: [PATCH 10/21] rename the workflows --- .github/workflows/CLI-ActixPostgres-CI.yml | 2 +- .github/workflows/CLI-ActixSqlite-CI.yml | 2 +- .github/workflows/CLI-PoemPostgres-CI.yml | 2 +- .github/workflows/CLI-PoemSqlite-CI.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index f52f5278..292fcc72 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -1,4 +1,4 @@ -name: CLI Continuous Integration (project compilation tests) +name: CLI Continuous Integration (Compilation tests for variations of Actix + Postgres) on: workflow_dispatch: push: diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 0448820f..d2cdc04c 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -1,4 +1,4 @@ -name: CLI Continuous Integration (project compilation tests) +name: CLI Continuous Integration (Compilation tests for variations of Actix + Sqlite) on: workflow_dispatch: push: diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index 83bc61d7..ad1c42fc 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -1,4 +1,4 @@ -name: CLI Continuous Integration (project compilation tests) +name: CLI Continuous Integration (Compilation tests for variations of Poem + Postgres) on: workflow_dispatch: push: diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index 39a6dc7b..95c87cae 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -1,4 +1,4 @@ -name: CLI Continuous Integration (project compilation tests) +name: CLI Continuous Integration (Compilation tests for variations of Poem + Sqlite) on: workflow_dispatch: push: From 33cb7b837f0b88634c149122e25cd3942ee38b40 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:28:44 -0800 Subject: [PATCH 11/21] cargo fmt --- create-rust-app/src/dev/backend_compiling_server.rs | 2 +- create-rust-app_cli/src/main.rs | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/create-rust-app/src/dev/backend_compiling_server.rs b/create-rust-app/src/dev/backend_compiling_server.rs index 610e71ff..4214423b 100644 --- a/create-rust-app/src/dev/backend_compiling_server.rs +++ b/create-rust-app/src/dev/backend_compiling_server.rs @@ -134,7 +134,7 @@ pub async fn start( // println!("=> ignoring {:#?}", files_to_ignore); let mut touched_migrations_dir = false; - + // no file events if !action.events.iter().any(|e| { e.tags.iter().any(|t| match t { diff --git a/create-rust-app_cli/src/main.rs b/create-rust-app_cli/src/main.rs index 55d845d8..a60fc388 100644 --- a/create-rust-app_cli/src/main.rs +++ b/create-rust-app_cli/src/main.rs @@ -61,7 +61,7 @@ enum Commands { name = "non-interactive mode", help = "Configure project through interactive CLI arguments.", requires = "database", - requires = "backend framework", + requires = "backend framework" )] cli_mode: bool, @@ -336,8 +336,7 @@ fn create_project( } features - } - else { + } else { vec![] } } From 387ab6a3caf6cfdc7a48e01f8816899b85cccd78 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:35:03 -0800 Subject: [PATCH 12/21] fix commands --- .github/workflows/CLI-ActixPostgres-CI.yml | 21 ++++++++++++++------- .github/workflows/CLI-ActixSqlite-CI.yml | 21 ++++++++++++++------- .github/workflows/CLI-PoemPostgres-CI.yml | 18 ++++++++++++------ .github/workflows/CLI-PoemSqlite-CI.yml | 18 ++++++++++++------ 4 files changed, 52 insertions(+), 26 deletions(-) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index 292fcc72..1606b7b9 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -41,7 +41,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -67,7 +68,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -93,7 +95,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=container test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=container test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -119,7 +122,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -145,7 +149,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=storage test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=storage test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -171,7 +176,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=graphql test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=graphql test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -197,7 +203,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,utoipa test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,utoipa test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index d2cdc04c..0e61df01 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -42,7 +42,8 @@ jobs: - uses: actions-rs/cargo@v1.0.3 with: command: - cargo run --bin create-rust-app -- create -c -d sqlite -b actix-web test-project + cargo run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -69,7 +70,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -95,7 +97,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=container test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=container test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -121,7 +124,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -147,7 +151,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=storage test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=storage test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -173,7 +178,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=graphql test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=graphql test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -199,7 +205,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,utoipa test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,utoipa test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index ad1c42fc..67815465 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -41,7 +41,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b poem test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b poem test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -67,7 +68,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth,container,graphql,storage test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth,container,graphql,storage test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -93,7 +95,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=container test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=container test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -119,7 +122,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -145,7 +149,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=storage test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=storage test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -171,7 +176,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d postgres -b poem --plugins=graphql test-project + command: run + args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=graphql test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index 95c87cae..520da1f2 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -41,7 +41,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b poem test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b poem test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -68,7 +69,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth,container,graphql,storage test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth,container,graphql,storage test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -94,7 +96,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=container test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=container test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -120,7 +123,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -146,7 +150,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=storage test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=storage test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: @@ -172,7 +177,8 @@ jobs: key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1.0.3 with: - command: run --bin create-rust-app -- create -c -d sqlite -b poem --plugins=graphql test-project + command: run + args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=graphql test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: From 2ee80cc1164f94c11f4066252fa39e26d54474c3 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:44:21 -0800 Subject: [PATCH 13/21] configure a git username for use in each test --- .github/workflows/CLI-ActixPostgres-CI.yml | 7 +++++++ .github/workflows/CLI-ActixSqlite-CI.yml | 7 +++++++ .github/workflows/CLI-PoemPostgres-CI.yml | 6 ++++++ .github/workflows/CLI-PoemSqlite-CI.yml | 6 ++++++ 4 files changed, 26 insertions(+) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index 1606b7b9..53005b5e 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -39,6 +39,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -66,6 +67,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -93,6 +95,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -120,6 +123,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -147,6 +151,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -174,6 +179,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -201,6 +207,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 0e61df01..d9f4da45 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -39,6 +39,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: @@ -68,6 +69,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -95,6 +97,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -122,6 +125,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -149,6 +153,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -176,6 +181,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -203,6 +209,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index 67815465..8b1e6e6d 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -39,6 +39,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -66,6 +67,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -93,6 +95,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -120,6 +123,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -147,6 +151,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -174,6 +179,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index 520da1f2..30b3a6e1 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -39,6 +39,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -67,6 +68,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -94,6 +96,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -121,6 +124,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -148,6 +152,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -175,6 +180,7 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} + - run: git config user.name test - uses: actions-rs/cargo@v1.0.3 with: command: run From d28b983f74710c358afd917c14009fa0fd57b1df Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 20:57:15 -0800 Subject: [PATCH 14/21] add git email --- .github/workflows/CLI-ActixPostgres-CI.yml | 7 +++++++ .github/workflows/CLI-ActixSqlite-CI.yml | 7 +++++++ .github/workflows/CLI-PoemPostgres-CI.yml | 6 ++++++ .github/workflows/CLI-PoemSqlite-CI.yml | 6 ++++++ 4 files changed, 26 insertions(+) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index 53005b5e..41a366aa 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -40,6 +40,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -68,6 +69,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -96,6 +98,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -124,6 +127,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -152,6 +156,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -180,6 +185,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -208,6 +214,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index d9f4da45..26597cb8 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -40,6 +40,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: @@ -70,6 +71,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -98,6 +100,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -126,6 +129,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -154,6 +158,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -182,6 +187,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -210,6 +216,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index 8b1e6e6d..4f656cbf 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -40,6 +40,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -68,6 +69,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -96,6 +98,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -124,6 +127,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -152,6 +156,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -180,6 +185,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index 30b3a6e1..ef16de98 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -40,6 +40,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -69,6 +70,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -97,6 +99,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -125,6 +128,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -153,6 +157,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -181,6 +186,7 @@ jobs: **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - run: git config user.name test + - run: git config user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run From 26b91f85cb4e0c4468b9f251ed8be9f94839071c Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 21:02:21 -0800 Subject: [PATCH 15/21] try setting global configuration? --- .github/workflows/CLI-ActixPostgres-CI.yml | 28 +++++++++++----------- .github/workflows/CLI-ActixSqlite-CI.yml | 28 +++++++++++----------- .github/workflows/CLI-PoemPostgres-CI.yml | 24 +++++++++---------- .github/workflows/CLI-PoemSqlite-CI.yml | 24 +++++++++---------- 4 files changed, 52 insertions(+), 52 deletions(-) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index 41a366aa..dc0aead4 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -39,8 +39,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -68,8 +68,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -97,8 +97,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -126,8 +126,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -155,8 +155,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -184,8 +184,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -213,8 +213,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 26597cb8..1e485682 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -39,8 +39,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: @@ -70,8 +70,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -99,8 +99,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -128,8 +128,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -157,8 +157,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -186,8 +186,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -215,8 +215,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-AS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index 4f656cbf..bd0f6916 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -39,8 +39,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -68,8 +68,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -97,8 +97,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -126,8 +126,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -155,8 +155,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -184,8 +184,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PP-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index ef16de98..c6e7025e 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -39,8 +39,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -69,8 +69,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -98,8 +98,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -127,8 +127,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -156,8 +156,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run @@ -185,8 +185,8 @@ jobs: **/.cargo/.build **/target key: ${{ runner.os }}-cargo-cli-PS-${{ hashFiles('**/Cargo.lock') }} - - run: git config user.name test - - run: git config user.email example@email.com + - run: git config --global user.name test + - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: command: run From eb2af04309de8636fa65c107241be7b54bc7f2b9 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 21:17:39 -0800 Subject: [PATCH 16/21] . --- .github/workflows/CLI-ActixSqlite-CI.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 1e485682..1cf46190 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -43,14 +43,12 @@ jobs: - run: git config --global user.email example@email.com - uses: actions-rs/cargo@v1.0.3 with: - command: - cargo run + command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web test-project - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: - command: - cargo build + command: build Actix-Sqlite-All: needs: [Actix-Sqlite-None] From 5fbdb798f47b0fa3f513ac30ee3d64a1def9549e Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 21:25:42 -0800 Subject: [PATCH 17/21] make it actually compile the generated project --- .github/workflows/CLI-ActixPostgres-CI.yml | 18 +++++++++--------- .github/workflows/CLI-ActixSqlite-CI.yml | 18 +++++++++--------- .github/workflows/CLI-PoemPostgres-CI.yml | 14 +++++++------- .github/workflows/CLI-PoemSqlite-CI.yml | 14 +++++++------- 4 files changed, 32 insertions(+), 32 deletions(-) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index dc0aead4..da757b56 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -45,10 +45,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b actix-web test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Postgres-All: needs: [Actix-Postgres-None] @@ -74,10 +74,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Postgres-Container: needs: [Actix-Postgres-None] @@ -103,10 +103,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=container test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Postgres-Auth: needs: [Actix-Postgres-None] @@ -132,10 +132,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Postgres-Storage: needs: [Actix-Postgres-None] @@ -161,10 +161,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=storage test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Postgres-GraphQL: needs: [Actix-Postgres-None] @@ -189,11 +189,11 @@ jobs: - uses: actions-rs/cargo@v1.0.3 with: command: run - args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=graphql test-project - - run: cd test-project + args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=graphql,auth test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Postgres-Utoipa: needs: [Actix-Postgres-None] @@ -219,7 +219,7 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b actix-web --plugins=auth,utoipa test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: - command: build \ No newline at end of file + command: build + args: --manifest-path=test-project/Cargo.toml \ No newline at end of file diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 1cf46190..3f2a97aa 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -45,10 +45,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Sqlite-All: needs: [Actix-Sqlite-None] @@ -74,10 +74,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,container,graphql,storage,utoipa test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Sqlite-Container: needs: [Actix-Sqlite-None] @@ -103,10 +103,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=container test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Sqlite-Auth: needs: [Actix-Sqlite-None] @@ -132,10 +132,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Sqlite-Storage: needs: [Actix-Sqlite-None] @@ -161,10 +161,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=storage test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Sqlite-GraphQL: needs: [Actix-Sqlite-None] @@ -189,11 +189,11 @@ jobs: - uses: actions-rs/cargo@v1.0.3 with: command: run - args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=graphql test-project - - run: cd test-project + args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=graphql,auth test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Actix-Sqlite-Utoipa: needs: [Actix-Sqlite-None] @@ -219,7 +219,7 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b actix-web --plugins=auth,utoipa test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: - command: build \ No newline at end of file + command: build + args: --manifest-path=test-project/Cargo.toml \ No newline at end of file diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index bd0f6916..56231857 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -45,10 +45,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b poem test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Postgres-All: needs: [Poem-Postgres-None] @@ -74,10 +74,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth,container,graphql,storage test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Postgres-Container: needs: [Poem-Postgres-None] @@ -103,10 +103,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=container test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Postgres-Auth: needs: [Poem-Postgres-None] @@ -132,10 +132,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=auth test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Postgres-Storage: needs: [Poem-Postgres-None] @@ -161,10 +161,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=storage test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Postgres-GraphQL: needs: [Poem-Postgres-None] @@ -189,8 +189,8 @@ jobs: - uses: actions-rs/cargo@v1.0.3 with: command: run - args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=graphql test-project - - run: cd test-project + args: --bin create-rust-app -- create -c -d postgres -b poem --plugins=graphql,auth test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index c6e7025e..1e295a6c 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -45,10 +45,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b poem test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Sqlite-All: @@ -75,10 +75,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth,container,graphql,storage test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Sqlite-Container: needs: [Poem-Sqlite-None] @@ -104,10 +104,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=container test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Sqlite-Auth: needs: [Poem-Sqlite-None] @@ -133,10 +133,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=auth test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Sqlite-Storage: needs: [Poem-Sqlite-None] @@ -162,10 +162,10 @@ jobs: with: command: run args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=storage test-project - - run: cd test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml Poem-Sqlite-GraphQL: needs: [Poem-Sqlite-None] @@ -190,8 +190,8 @@ jobs: - uses: actions-rs/cargo@v1.0.3 with: command: run - args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=graphql test-project - - run: cd test-project + args: --bin create-rust-app -- create -c -d sqlite -b poem --plugins=graphql,auth test-project - uses: actions-rs/cargo@v1.0.3 with: command: build + args: --manifest-path=test-project/Cargo.toml From 6225dc7d4f3ce1403ae11aa244e0139e0a4ab042 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 21:33:35 -0800 Subject: [PATCH 18/21] pointless commit to trigger CI --- create-rust-app_cli/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/create-rust-app_cli/src/main.rs b/create-rust-app_cli/src/main.rs index a60fc388..2fbb3b3d 100644 --- a/create-rust-app_cli/src/main.rs +++ b/create-rust-app_cli/src/main.rs @@ -461,7 +461,7 @@ fn configure_project( println!("Fatal: the current directory doesn't exist. This shouldn't be possible."); return Ok(()); } - + if !fs::is_rust_project(¤t_dir)? { // TODO: determine if the current directory is a create-rust-app project. println!("Fatal: the current directory is not a rust project."); From b1fa95f235772a65072e2a528d833f54dae4080a Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 21:33:48 -0800 Subject: [PATCH 19/21] revert previous commit --- create-rust-app_cli/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/create-rust-app_cli/src/main.rs b/create-rust-app_cli/src/main.rs index 2fbb3b3d..a60fc388 100644 --- a/create-rust-app_cli/src/main.rs +++ b/create-rust-app_cli/src/main.rs @@ -461,7 +461,7 @@ fn configure_project( println!("Fatal: the current directory doesn't exist. This shouldn't be possible."); return Ok(()); } - + if !fs::is_rust_project(¤t_dir)? { // TODO: determine if the current directory is a create-rust-app project. println!("Fatal: the current directory is not a rust project."); From 5ce51940d861135389107fa3b286c5e70439bd68 Mon Sep 17 00:00:00 2001 From: AnthonyMichaelTDM <68485672+AnthonyMichaelTDM@users.noreply.github.com> Date: Tue, 21 Feb 2023 21:43:58 -0800 Subject: [PATCH 20/21] change workflow groups --- .github/workflows/CLI-ActixPostgres-CI.yml | 2 +- .github/workflows/CLI-ActixSqlite-CI.yml | 2 +- .github/workflows/CLI-PoemPostgres-CI.yml | 2 +- .github/workflows/CLI-PoemSqlite-CI.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/CLI-ActixPostgres-CI.yml b/.github/workflows/CLI-ActixPostgres-CI.yml index da757b56..8f692063 100644 --- a/.github/workflows/CLI-ActixPostgres-CI.yml +++ b/.github/workflows/CLI-ActixPostgres-CI.yml @@ -17,7 +17,7 @@ env: CARGO_TERM_COLOR: always concurrency: - group: CI-${{ github.ref }} + group: CI-AP-${{ github.ref }} cancel-in-progress: true jobs: diff --git a/.github/workflows/CLI-ActixSqlite-CI.yml b/.github/workflows/CLI-ActixSqlite-CI.yml index 3f2a97aa..b292bff5 100644 --- a/.github/workflows/CLI-ActixSqlite-CI.yml +++ b/.github/workflows/CLI-ActixSqlite-CI.yml @@ -17,7 +17,7 @@ env: CARGO_TERM_COLOR: always concurrency: - group: CI-${{ github.ref }} + group: CI-AS-${{ github.ref }} cancel-in-progress: true jobs: diff --git a/.github/workflows/CLI-PoemPostgres-CI.yml b/.github/workflows/CLI-PoemPostgres-CI.yml index 56231857..5b4713d7 100644 --- a/.github/workflows/CLI-PoemPostgres-CI.yml +++ b/.github/workflows/CLI-PoemPostgres-CI.yml @@ -17,7 +17,7 @@ env: CARGO_TERM_COLOR: always concurrency: - group: CI-${{ github.ref }} + group: CI-PP-${{ github.ref }} cancel-in-progress: true jobs: diff --git a/.github/workflows/CLI-PoemSqlite-CI.yml b/.github/workflows/CLI-PoemSqlite-CI.yml index 1e295a6c..5a1d223a 100644 --- a/.github/workflows/CLI-PoemSqlite-CI.yml +++ b/.github/workflows/CLI-PoemSqlite-CI.yml @@ -17,7 +17,7 @@ env: CARGO_TERM_COLOR: always concurrency: - group: CI-${{ github.ref }} + group: CI-PS-${{ github.ref }} cancel-in-progress: true jobs: From 29be0b63d0817382c5898b54a75bcb7ffdad2423 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 3 Mar 2023 16:07:38 +0000 Subject: [PATCH 21/21] Bump @playwright/test in /create-rust-app_cli/template/frontend Bumps [@playwright/test](https://github.com/Microsoft/playwright) from 1.30.0 to 1.31.2. - [Release notes](https://github.com/Microsoft/playwright/releases) - [Commits](https://github.com/Microsoft/playwright/compare/v1.30.0...v1.31.2) --- updated-dependencies: - dependency-name: "@playwright/test" dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../template/frontend/package-lock.json | 15 ++++++++------- .../template/frontend/package.json | 2 +- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/create-rust-app_cli/template/frontend/package-lock.json b/create-rust-app_cli/template/frontend/package-lock.json index 32d424e7..d1ad952d 100644 --- a/create-rust-app_cli/template/frontend/package-lock.json +++ b/create-rust-app_cli/template/frontend/package-lock.json @@ -460,19 +460,20 @@ } }, "@playwright/test": { - "version": "1.30.0", - "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.30.0.tgz", - "integrity": "sha512-SVxkQw1xvn/Wk/EvBnqWIq6NLo1AppwbYOjNLmyU0R1RoQ3rLEBtmjTnElcnz8VEtn11fptj1ECxK0tgURhajw==", + "version": "1.31.2", + "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.31.2.tgz", + "integrity": "sha512-BYVutxDI4JeZKV1+ups6dt5WiqKhjBtIYowyZIJ3kBDmJgsuPKsqqKNIMFbUePLSCmp2cZu+BDL427RcNKTRYw==", "dev": true, "requires": { "@types/node": "*", - "playwright-core": "1.30.0" + "fsevents": "2.3.2", + "playwright-core": "1.31.2" }, "dependencies": { "playwright-core": { - "version": "1.30.0", - "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.30.0.tgz", - "integrity": "sha512-7AnRmTCf+GVYhHbLJsGUtskWTE33SwMZkybJ0v6rqR1boxq2x36U7p1vDRV7HO2IwTZgmycracLxPEJI49wu4g==", + "version": "1.31.2", + "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.31.2.tgz", + "integrity": "sha512-a1dFgCNQw4vCsG7bnojZjDnPewZcw7tZUNFN0ZkcLYKj+mPmXvg4MpaaKZ5SgqPsOmqIf2YsVRkgqiRDxD+fDQ==", "dev": true } } diff --git a/create-rust-app_cli/template/frontend/package.json b/create-rust-app_cli/template/frontend/package.json index cbdb871a..4fe15efb 100644 --- a/create-rust-app_cli/template/frontend/package.json +++ b/create-rust-app_cli/template/frontend/package.json @@ -36,7 +36,7 @@ ] }, "devDependencies": { - "@playwright/test": "^1.30.0", + "@playwright/test": "^1.31.2", "@types/node": "^18.13.0", "@types/react": "^18.0.27", "@types/react-dom": "^18.0.10",