diff --git a/.gitignore b/.gitignore index 5461a20..bb56c36 100644 --- a/.gitignore +++ b/.gitignore @@ -4,7 +4,7 @@ # Remove Cargo.lock from gitignore if creating an executable, leave it for libraries # More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html -Cargo.lock +# Cargo.lock # These are backup files generated by rustfmt **/*.rs.bk diff --git a/.gitmodules b/.gitmodules index 808d58f..fa84eb0 100644 --- a/.gitmodules +++ b/.gitmodules @@ -22,3 +22,6 @@ [submodule "apps/main"] path = apps/main url = git@github.com:najamelan/ekke_main +[submodule "ekke_core_frontend"] + path = ekke_core_frontend + url = git@github.com:ekke-rs/ekke_core_frontend.git diff --git a/Cargo.toml b/Cargo.toml deleted file mode 100644 index 4c6c768..0000000 --- a/Cargo.toml +++ /dev/null @@ -1,15 +0,0 @@ -[workspace] - - members = [ - - "ekke_core" , - "ekke_io" , - "ekke_config" , - "ekke_merge" , - "ekke_merge_derive" , - - #"apps/filebrowser" , - "apps/main/main_backend" , - "apps/main/main_frontend" , - #"apps/systemd" , - ] diff --git a/Makefile.fish b/Makefile.fish new file mode 100755 index 0000000..7c1c724 --- /dev/null +++ b/Makefile.fish @@ -0,0 +1,108 @@ +#! /usr/bin/fish + + +set --global libs \ + \ + ekke_config \ + ekke_io \ + ekke_merge \ + ekke_merge_derive \ + + +set --global back_execs \ + \ + ekke_core \ + + +set --global wasm_execs \ + \ + ekke_core_frontend \ + + +set --global all_execs $back_execs $wasm_execs +set --global crates $back_execs $wasm_execs $libs + +set --global server ekke_core + + + +function build + + for crate in $wasm_execs + + pushd $crate + + echo "wasm-pack build $argv[1] $crate" + + wasm-pack build $argv[1] --target no-modules; or exit 1 + + popd + + end + + for crate in $back_execs + + pushd $crate + + echo "Build $argv[1] $crate" + + cargo build $argv[1] ; or exit 1 + + popd + + end + +end + + +function check + + for crate in $all_execs + + pushd $crate + + echo "Check $crate" + + cargo check; or exit 1 + + popd + + end + +end + + +function run + + build; or exit 1 + + pushd $server + + echo "Run $argv[1] Ekke Server" + cargo run $argv[1] + + popd + +end + + +# When running cargo commands on an executable, cargo yaml won't be called on it's +# dependencies. We have a custom wrapper for cargo that calls it wherever cargo is +# called, but the cargo command won't be called in the shell to build dependencies... +# +for crate in $crates + + pushd $crate + + cargo > /dev/null + + popd + +end + +if test (count $argv) -eq 0 ; check; exit ; end +if test $argv[1] = "check" ; check ; end +if test $argv[1] = "build" ; build ; end +if test $argv[1] = "run" ; run ; end +if test $argv[1] = "buildrel" ; build --release ; end +if test $argv[1] = "runrel" ; run --release ; end diff --git a/Makefile.toml b/Makefile.toml deleted file mode 100644 index bb85317..0000000 --- a/Makefile.toml +++ /dev/null @@ -1,31 +0,0 @@ -[tasks.run] - - description = "Run ekke" - workspace = false - - script = [ - - "cargo build --all", - - "pushd apps/main/main_frontend", - "wasm-pack build --target no-modules", - "popd", - "cargo run --bin ekke", - - ] - -[tasks.runrelease] - - description = "Run ekke" - workspace = false - - script = [ - - "cargo build --all --release", - - "pushd apps/main/main_frontend", - "wasm-pack build --release --target no-modules --no-typescript", - "popd", - "cargo run --release --bin ekke", - - ] diff --git a/README.md b/README.md index 16170d7..ce4f692 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,42 @@ # ekke -Application framework in Rust + +EKKE IS CURRENTLY WIP AND NOT PRODUCTION READY (this readme serves me for taking notes for later...) + +Ekke is an application framework for building cross platform GUI apps that run both locally and on the web. The general purpose is to allow for each application to be developed by writing stricly its actual functionality. Ekke will take care of all annoying chores for you: installation, deployment, configuration, logging, user auth, reusable frontend components like powerful fuzzy search/command bar, ... Write nothing but your actual functionality. + +If all you want to do is write a CLI application, you probably don't want to bother using the ekke framework. If you want cross platform GUI and deploy to phone, desktop and web at once, Ekke should save you alot of time. + +When writing an application with ekke, you are locked in: + +- writing a frontend with web technologies: + 1. structure: html + 2. styling : css/scss/less/sass... + 3. logic : webassembly/javascript/typescript/elm/purescript... + +- Separating your frontend and backend in 2 components +- Components in ekke must communicate in ekkespeak (CBOR encoded messages) +- Require the ekke server to run alongside your application + +Ekke will provide you with the following advantages: + +- all your backend has to do is connect to a socket and understand ekkespeak. You need not worry about any low level stuff like setting up http etc... +- you can use any programming language for your backend. You can choose any database for your backend. +- ekke can be compiled into your program as a library, or you can deploy your program for people already running ekke through package management. +- reusable frontend components for consistent user experience (powerful instant search bar that can also send commands to your backend,...) +- ekke will take care of repetitive chores like installation/deployment/configuration/logging/user auth/... +- if you develop in rust you have additional benefits, you can compile agains the ekke libs to have acces to all structs and traits directly, so you don't have to implement ekkespeak, nor socket connection. All + + + + + + + + + + + +- reusblility of functionality (do as little as possible in apps) +- be careful not to lock apps in xxx +- + diff --git a/apps/main b/apps/main index a085a25..0c028e9 160000 --- a/apps/main +++ b/apps/main @@ -1 +1 @@ -Subproject commit a085a251d17d9c6cea9d0ddf18fba82ff10b07b7 +Subproject commit 0c028e983590d69b5adea92a60a504fcb934b45d diff --git a/ekke_config b/ekke_config index 409c45e..01ed961 160000 --- a/ekke_config +++ b/ekke_config @@ -1 +1 @@ -Subproject commit 409c45e6cf428eabd7a388bbefe729bc82078ead +Subproject commit 01ed961aef13490b8e9a30cea9de3123d226bcf7 diff --git a/ekke_core b/ekke_core index 4e5050e..b4f6924 160000 --- a/ekke_core +++ b/ekke_core @@ -1 +1 @@ -Subproject commit 4e5050e2686271b01c4cd533db0b48f3ef7e9bcf +Subproject commit b4f69246f1ed069848eadff6eb5673ab41fbf894 diff --git a/ekke_core_frontend b/ekke_core_frontend new file mode 160000 index 0000000..37d4ffe --- /dev/null +++ b/ekke_core_frontend @@ -0,0 +1 @@ +Subproject commit 37d4ffeafa24bc3fa0940d3094288931a0025b53 diff --git a/ekke_io b/ekke_io index 4f8c49b..2d2f9ff 160000 --- a/ekke_io +++ b/ekke_io @@ -1 +1 @@ -Subproject commit 4f8c49bca2b3f54fa3da72870c02ac4ab65a3fda +Subproject commit 2d2f9ff7315fe922c4ac2380a33d6846121e6d30 diff --git a/ekke_merge b/ekke_merge index 246b6b5..339b29b 160000 --- a/ekke_merge +++ b/ekke_merge @@ -1 +1 @@ -Subproject commit 246b6b506b45912dda5fa218b5ffefcc1af89c68 +Subproject commit 339b29b9c85927d81dd23db4f348780836e1f30e diff --git a/ekke_merge_derive b/ekke_merge_derive index 224c53e..3dc8b7f 160000 --- a/ekke_merge_derive +++ b/ekke_merge_derive @@ -1 +1 @@ -Subproject commit 224c53eb630905b3dfff4292e07e3898a90ee729 +Subproject commit 3dc8b7f4fd61d83c61491161e77f9abdfb8814ed