How do you add a directory?
ezhang7423 opened this issue · 2 comments
ezhang7423 commented
ubuntu@base ~/d/runs (main) [1]> dud stage add 2023-07-24
Error: 2023-07-24: yaml: input error: read 2023-07-24: is a directory
If this isn't supported, it seems like a pretty essential feature...
thorstenwagner commented
Mh, it works different:
- Add your directory to stage file
dud stage gen -o my/dir/ | tee my_dir.yaml
- Add stage
dud stage add my_dir.yaml
Do the rest:
dud commit
dud push
git add .
git commit -m "Added dir"
git push
kevin-hanselman commented
Thanks for the question, @ezhang7423! Sorry for the late response; I was away on vacation for a while.
@thorstenwagner has shown how this is done in Dud; thanks a bunch, @thorstenwagner!
TLDR: stage gen
generates/creates a stage file, and stage add
adds a stage file to Dud's index.