Skip to content

Compiler fails silently if no output file is selected #22

@changemewtf

Description

@changemewtf

Create this folder structure:

.
|-- Gemfile
|-- Guardfile
|-- application.coffee
`-- static/

With this Guardfile:

guard 'coffeescript', input: '', output: 'static' do
  watch 'application.coffee'
end

Guard will output Successfully generated static/application.js when application.coffee is changed, but no file will be created.

This is due to the detect_nested_directories method using patterns.product(files) to generate output locations when :shallow is set to false (the default).

Perhaps this error message would be appropriate:

ArgumentError: Ambiguous output directory for application.js. Try setting :shallow to true.

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