grlx icon indicating copy to clipboard operation
grlx copied to clipboard

[BUG] `file.append` `makedirs` doesn't work.

Open johnmckenna-snd opened this issue 1 year ago • 5 comments

Please describe the issue. If try to make a file and it's directories it doesn't wok.

# doesn't work where prom-config doesn't exist
# returns error: ERROR        json: cannot unmarshal object into Go struct field StepCompletion.Error of type error        listener.go:74
steps:
  create-boilerplate-file:
    file.append:
      - name: /home/sensor/prom-config/prometheus.yml
      - makedirs: true
      - text: "boilerplate"

# this works if it only has to create the file
steps:
  create-boilerplate-file:
    file.append:
      - name: /home/sensor/prometheus.yml
      - makedirs: true
      - text: "boilerplate"

Does this bug exist on the tip of master? [x] Yes [ ] No

Please note that bugfixes will only be ported to previous major versions at the request of a Sponsor, and only when applicable and possible. It is recommended all grlx users run the lastest stable release to take advantage of the newest features and bug fixes.

Configuration

Please upload the configuration files used if applicable.

johnmckenna-snd avatar Aug 19 '24 23:08 johnmckenna-snd

if you're willing to test drive #d32e19b it should address this issue (tip of dev branch)

taigrr avatar Aug 19 '24 23:08 taigrr

i can do that! probably in the next week or so.

johnmckenna-snd avatar Aug 19 '24 23:08 johnmckenna-snd

Cool. I am unable to publish a new version of grlx just yet, I've made a few API breaking changes to exported functions so the next release will be a v2 / major release. I'm trying to figure out all of my API breaking changes at once so I'm not at version 300 by the end of the year a la Kubernetes :laughing:

taigrr avatar Aug 19 '24 23:08 taigrr

Ok sounds good! I am looking forward to it.

johnmckenna-snd avatar Aug 19 '24 23:08 johnmckenna-snd

I just wanted to follow up here. I have not had the time to check this out, but I should soon!

johnmckenna-snd avatar Sep 19 '24 00:09 johnmckenna-snd

This was addressed in the most recent release.

taigrr avatar Oct 31 '24 20:10 taigrr

Awesome thank you! I am sorry I wasn't able to get around to testing this pre-release. I have a new batch of products I'm building soon, so I will test then.

johnmckenna-snd avatar Oct 31 '24 20:10 johnmckenna-snd