coffee-tools / coffee

Reference implementation for a flexible core lightning plugin manager
https://docs.page/coffee-tools/coffee
9 stars 13 forks source link

feat: branch support in installation #224

Closed royalpinto007 closed 5 months ago

royalpinto007 commented 6 months ago

Enables users to specify a branch during plugin installation in Coffee. This PR is a work in progress and not yet completed.

Reference- https://github.com/coffee-tools/coffee/issues/205

netlify[bot] commented 6 months ago

Deploy Preview for coffee-docs canceled.

Name Link
Latest commit 070e6d74bb40f6ee146ce9fee1623a7daac458ce
Latest deploy log https://app.netlify.com/sites/coffee-docs/deploys/65c36f4919cc910008bbc7e8
royalpinto007 commented 6 months ago

I don't see any issue with make check as it gives positive result, but integration testing fails.

For your reference-

royalpinto007@royalpinto007:~/coffee-dev$ make check
cargo test ""
    Finished test [unoptimized + debuginfo] target(s) in 1.46s
     Running unittests src/main.rs (target/debug/deps/coffee-a289af62a1ab4e5a)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running unittests src/lib.rs (target/debug/deps/coffee_core-1e57aab876cba5b9)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running unittests src/lib.rs (target/debug/deps/coffee_github-e12265faf851f5bf)

running 1 test
test tests::repository_is_initialized_ok ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 47.67s

     Running unittests src/lib.rs (target/debug/deps/coffee_httpd-9e02626a42513cf1)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running unittests src/main.rs (target/debug/deps/coffee_httpd-7b9b9d4b60a3f65c)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running unittests src/lib.rs (target/debug/deps/coffee_lib-e5e59cccfc42ee14)

running 3 tests
test plugin_conf::tests::test_remote ... ok
test url::tests::test_remote ... ok
test utils::tests::test_create_dir_in_home ... ok

test result: ok. 3 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.02s

     Running unittests src/main.rs (target/debug/deps/coffee_plugin-9a4709cab5419a40)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running unittests src/lib.rs (target/debug/deps/coffee_storage-1e89ec4f4e859c18)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running unittests src/lib.rs (target/debug/deps/coffee_testing-f5b11179a6057c76)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
vincenzopalazzo commented 6 months ago

Sorry It is my bad I give you the wrong information, this is the command that the CI runs https://github.com/coffee-tools/coffee/blob/master/docker/entrypoint.sh#L2

vincenzopalazzo commented 5 months ago

adding this to the milestone, but would love to have a summary of the status of this before starting review it

royalpinto007 commented 5 months ago

@vincenzopalazzo I initially created a starter code for implementing the branch functionality. Upon @tareknaser's suggestions, I developed a switch_branch function, as shown in this commit: https://github.com/coffee-tools/coffee/pull/224/commits/c664c667261d46229830049979dde5ec19ed2e40. After receiving some comments on it, I am currently at a standstill, as seen here: https://github.com/coffee-tools/coffee/pull/224#pullrequestreview-1845892587.