-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/trash dir #46
base: main
Are you sure you want to change the base?
Conversation
@@ -286,6 +290,8 @@ function unwatch(path, appid) | |||
end | |||
|
|||
function start(app) | |||
@info "inside start" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you remove all these debug messages please
app_path = joinpath(from_folder, app.name) | ||
|
||
if !isdir(app_path) | ||
@error "File '$app' is not a directory." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this rethrow and break? This will just continue even if the dir does not exist...
|
||
if(isdir(joinpath(to_folder, app.name))) | ||
timestamp = now() |> (dt -> trunc(dt, Minute)) |> (dt -> Dates.format(dt, "yyyy-mm-ddTHH:MM")) |> (s -> replace(s, r"[-:]" => "")) | ||
app_new_name = app.name * timestamp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here we should have a separator between app name and timestamp, like __
so we can split/undo the change.
@AbhimanyuAryan How do we handle the restore? When we undelete an app - it should reverse the changes. Move out of trash, remove timestamp from app name, etc. |
can merge ✅ |
tested on windows/macOS. Can be merged