Closed acg closed 4 years ago
Oh noooo, I had the code in my repo last night, I just had to push it ;-;
I'll go through this later today tho
Ha! No worries. Note that this does more than --append
, it also does --update
, which is probably the most common operation for me and I'm guessing others. Nice work putting this together btw!
Yeah, #3 was wanting to do a similar thing, but it felt out of scope, but it sounds like there's enough desire to have at least some sort of smart replace.
Maybe instead of --update
, we can call it --clear-previous
, and instead of removing every child, just removing any child PageBlock that matches the same name as the MD file? Does that sound good to you? I can implement this real quick, and it feels a bit safer and more inline with expectations if say, someone changes their MD file and expects the changes to persist
Alright, implemented in https://github.com/Cobertos/md2notion/pull/11, let me know how that looks.
This should be resolved in #11
Fixes #9. Adds three modal options:
--append
,--update
, and--create
(the default and current behavior). This lets you modify the parent page instead of always creating a new child page. If you pass--update
, the parent page's nodes will first be soft-removed so they can be replaced.