abra cp enhancements #390

Merged
3wordchant merged 1 commits from p4u1/abra:cp-enhancements into main 2023-12-02 15:39:28 +00:00
Member

Working on coop-cloud/organising#534

TODO:

  • local to server
    • file to dir
    • file to file (create)
    • file to file (override)
    • file to file (rename)
    • dir to dir
    • files to dir
  • server to local
    • file to dir
    • file to file (create)
    • file to file (override)
    • file to file (rename)
    • dir to dir
    • files to dir
Working on https://git.coopcloud.tech/coop-cloud/organising/issues/534 TODO: - [x] local to server - [x] file to dir - [x] file to file (create) - [x] file to file (override) - [x] file to file (rename) - [x] dir to dir - [x] files to dir - [x] server to local - [x] file to dir - [x] file to file (create) - [x] file to file (override) - [x] file to file (rename) - [x] dir to dir - [x] files to dir
p4u1 added 3 commits 2023-11-14 18:09:36 +00:00
p4u1 added 1 commit 2023-11-16 12:53:28 +00:00
continuous-integration/drone/pr Build is failing Details
f939308fce
rework copy to container and impement rename while copy
Owner

omg amazing @p4u1 😍

omg amazing @p4u1 😍
Author
Member

Thanks :) I got the local to server side done. It feels a bit hacky, but I think its worth it, since this is a nice usability upgrade.
Next up is the server to local side, but this should be easier, since I can reuse a lot of the code.
I'm also thinking about include and exclude flags, since it is already supported by the docker library.

Thanks :) I got the local to server side done. It feels a bit hacky, but I think its worth it, since this is a nice usability upgrade. Next up is the server to local side, but this should be easier, since I can reuse a lot of the code. I'm also thinking about include and exclude flags, since it is already supported by the docker library.
p4u1 added 5 commits 2023-11-20 20:31:33 +00:00
p4u1 reviewed 2023-11-20 20:34:51 +00:00
@ -5,9 +5,11 @@ setup_file(){
_common_setup
_add_server
_new_app
_deploy_app
Author
Member

@decentral1se I changed this test file, so that the app only gets deployed once for this file. This increases the time needed to rune the whole test file by a lot. Is this change ok? Otherwise I can change it back to how it was before.

@decentral1se I changed this test file, so that the app only gets deployed once for this file. This increases the time needed to rune the whole test file by a lot. Is this change ok? Otherwise I can change it back to how it was before.
decentral1se marked this conversation as resolved
Author
Member

@3wordchant This is ready for review now :)

@3wordchant This is ready for review now :)
p4u1 changed title from WIP: abra cp enhancements to abra cp enhancements 2023-11-20 21:48:05 +00:00
Owner

Will aim to review today, thanks so much @p4u1! 🙏

Will aim to review today, thanks so much @p4u1! 🙏
decentral1se reviewed 2023-11-27 09:55:32 +00:00
decentral1se left a comment
Owner

Solid stuff, some minor comments! Don't have time atm to run the test suite and such but when you're happy with it @p4u1, please do merge it. Thanks for working on this. I've added you to the org team, you have read/write permissions.

Solid stuff, some minor comments! Don't have time atm to run the test suite and such but when you're happy with it @p4u1, please do merge it. Thanks for working on this. I've added you to the org team, you have read/write permissions.
cli/app/cp.go Outdated
@ -91,1 +63,3 @@
}
srcPath, dstPath, service, toContainer, err := parseSrcAndDst(src, dst)
if err != nil {
log.Fatal(err)
Owner

logrus.Fatal(err)

`logrus.Fatal(err)`
p4u1 marked this conversation as resolved
cli/app/cp.go Outdated
@ -150,0 +292,4 @@
ErrDstDirNotExist = fmt.Errorf("destination directory does not exist")
)
func copyMode(srcPath, dstPath string, srcMode os.FileMode, dstMode os.FileMode, dstExists bool) (CopyMode, error) {
Owner

Missing docs string?

Missing docs string?
Author
Member

I added documentation to all copy modes and add a reference in here. See bd32d20a2b

I added documentation to all copy modes and add a reference in here. See https://git.coopcloud.tech/coop-cloud/abra/commit/bd32d20a2bbe96778d38bd90d9695f980c975b12
p4u1 marked this conversation as resolved
@ -69,2 +69,4 @@
return containers[0], nil
}
// Retrieves the container for the given stack and service.
Owner
// GetContainerFromStackAndService retrieves the container for the given stack and service.
```go // GetContainerFromStackAndService retrieves the container for the given stack and service. ```
p4u1 marked this conversation as resolved
p4u1 force-pushed cp-enhancements from a94dc125f4 to bd32d20a2b 2023-11-27 14:40:03 +00:00 Compare
Author
Member

@decentral1se Thanks for the review :) I added a new commit with the changes you suggested.

@3wordchant Do you want still want to review this? (Don't worry, if you need a few more days. I'm in no rush to merge this and would prefer a review from you before merging, since you authored the issue)

@decentral1se Thanks for the review :) I added a new commit with the changes you suggested. @3wordchant Do you want still want to review this? (Don't worry, if you need a few more days. I'm in no rush to merge this and would prefer a review from you before merging, since you authored the issue)
p4u1 force-pushed cp-enhancements from bd32d20a2b to 45d7e5f1fc 2023-12-01 11:26:11 +00:00 Compare
decentral1se reviewed 2023-12-02 11:44:39 +00:00
decentral1se left a comment
Owner

@p4u1 Oh, one other thing: could you change the commit to follow https://www.conventionalcommits.org/en/v1.0.0/ e.g. feat: abra cp enhancements because then it is less work to generate the change log when making releases. Thanks!

@p4u1 Oh, one other thing: could you change the commit to follow https://www.conventionalcommits.org/en/v1.0.0/ e.g. `feat: abra cp enhancements` because then it is less work to generate the change log when making releases. Thanks!
p4u1 force-pushed cp-enhancements from 45d7e5f1fc to 296b2e0312 2023-12-02 12:25:44 +00:00 Compare
3wordchant merged commit 2de6934322 into main 2023-12-02 15:39:28 +00:00
Owner

11/10, tested all the scenarios listen in #534 and they all work perfectly, huge congratulations and thanks @p4u1 ! 🎉

11/10, tested all the scenarios listen in #534 and they all work perfectly, huge congratulations and thanks @p4u1 ! 🎉
Sign in to join this conversation.
No description provided.