Skip to content

How to save all loaded files to a destination and keep directory structure #46

@blazp7

Description

@blazp7

Hi, im trying to create an ansible project using nix language. I have an entire directory of .nix files that are referencing each other through self, super, root and are structured in ansible compatible hierarchy. Now i would like to save these imported nix expressions to .yaml files in a new directory while keeping the hierarchy structure intact, so i can run ansible-playbook on it.

I was hoping there is some way to iterate over the files that haumena has loaded, with access to their relative filepath and the evaluated expression so i could do something like this (pkgs.formats.yaml {}).generate "path/filename.yml" nixexpr

Help much appreciated and thanks for your work on this project.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions