Hugo new command STDOUT changed in v0.89.0

Hi There,
I have been using the output of
hugo new --kind ARCHETYPE PATH/TO/FILE.md
to retrieve the filepath of the file created in an automation. However, I noticed that this behavior has changed after the archetype re-implementation Pull Request. and my automation now breaks. To be more precise, line 103 of hugo/create/content.go has been removed. For the moment I am using v0.88.1.

Example
EVENT_FILE_PATH=$(hugo new --kind EXAMPLE events/example/${FILENAME}.md | awk '{print $1}')
[[ -f "${EVENT_FILE_PATH}" ]] || exit 1
My question is: is this a bug or a planned change of behavior? Should I refactor my automation and avoid relying on Hugo CLI output?

Thansk a lot!

It was not planned – if you could open a issue on GitHub and I will put that print statement back in.

1 Like

Hi bep, great! Thanks for the clarification and prompt response. I have opened an issue, as requested.

Thanks a lot for developing and maintaining this amazing tool :slight_smile:

1 Like