Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for ignore-non-theme-folders configuration option #116

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions src/main/java/com/vaadin/integration/maven/CompileThemeMojo.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,16 @@ public class CompileThemeMojo extends AbstractThemeMojo {
@Parameter(defaultValue = "false", property = "vaadin.theme.ignore.warnings")
private boolean ignoreThemeWarnings;

/**
* Continues to compile even though a directory with no styles was encountered.
* This is useful to have a working theme compilation when using Subversion, Mercurial,
* Dimensions and other systems that create hidden folders next to the files they version.
* Note: If you have no theme and set this parameter to true the compilation will succeed despite.
*/
@Parameter(defaultValue = "false", property = "vaadin.theme.ignore.non-theme-folders")
private boolean ignoreNonThemeFolders;


@Override
protected void checkVaadinVersion() throws MojoExecutionException {
// restrict to Vaadin 7.0 and later, otherwise skip and log
Expand All @@ -52,6 +62,10 @@ protected void processTheme(String theme) throws MojoExecutionException {
if (ignoreThemeWarnings) {
cmd.arg("-ignore-warnings:true");
}

if(ignoreNonThemeFolders) {
cmd.arg("-ignore-non-theme-folders:true");
}

File themeDir = configureThemeClasspath(cmd, theme);

Expand Down