Sign inSign up

oliverlorenz/file-structure-checker

By oliverlorenz

•Updated over 6 years ago

Image
0

242

oliverlorenz/file-structure-checker repository overview

⁠file-structure-checker

This tool lets you easily check if a certain file and folder structure is present. The structure to be checked can be configured via a yaml file.

⁠usage

npm install -g file-structure-checker

create a .file-structure-checker.yml file in a directory you want to check. example:

vars:
  month: january
structure:
  name: ""
  type: directory
  children:
    - name: correspondence
      type: directory
      children:
        - name: letter.pdf
          type: file
        - name: invoice_${month}.pdf
          type: file

run:

file-system-checker

you will get a result like that:

$ file-structure-checker

 /
     ✓ is existing
     ✓ is directory

     /correspondence
         ✓ is existing
         ✓ is directory

         /letter.pdf
             ✕ is existing
             ✕ is file

         /invoice_january.pdf
             ✕ is existing
             ✕ is file

result:
 ✓ 4 ✕ 4

⁠docker

docker run -it --rm -v $(pwd):/volume oliverlorenz/file-structure-checker

Tag summary

Content type

Image

Digest

Size

49.4 MB

Last updated

over 6 years ago

docker pull oliverlorenz/file-structure-checker