Examples of JsLint


Examples of com.googlecode.jslint4java.JSLint

    }

    @Override
    public void execute() throws MojoExecutionException, MojoFailureException
    {
        JSLint jsLint = applyJSlintSource();
        applyDefaults();
        applyOptions(jsLint);
        List<File> files = getFilesToProcess();
        int failures = 0;
        ReportWriter reporter = new ReportWriter(new File(outputFolder, JSLINT_XML), new JSLintXmlFormatter());
View Full Code Here

Examples of com.googlecode.jslint4java.JSLint

            try {
                Context cx = contextFactory.enter();
                ScriptableObject scope = cx.initStandardObjects();
                Reader r = new InputStreamReader(Thread.currentThread().getContextClassLoader().getResourceAsStream(JSLINT_FILE), UTF8);
                cx.evaluateReader(scope, r, "jslint.js", 1, null);
                return new JSLint(contextFactory, scope);
            } catch (IOException ioe) {
                throw new MojoExecutionException("Cant' load jslint.js", ioe);
            } finally {
                Context.exit();
            }
View Full Code Here

Examples of com.googlecode.jslint4java.JSLint

        if (resources.size() == 0) {
            // issue 53: this isn't a fail, just a notice.
            log(NO_FILES_TO_LINT);
        }

        JSLint lint = makeLint();
        applyOptions(lint);

        for (ResultFormatter rf : formatters) {
            rf.begin();
        }
View Full Code Here

Examples of com.googlecode.jslint4java.JSLint

    public void execute() throws MojoExecutionException, MojoFailureException {
        if (skip) {
            getLog().info("skipping JSLint");
            return;
        }
        JSLint jsLint = applyJSlintSource();
        applyDefaults();
        applyOptions(jsLint);
        List<File> files = getFilesToProcess();
        int failures = 0;
        ReportWriter reporter = makeReportWriter();
View Full Code Here

Examples of com.googlecode.jslint4java.JSLint

            return;
        }

        BufferedReader reader = null;
        try {
            JSLint lint = lintProvider.getJsLint();
            // TODO: this should react to changes in the prefs pane instead.
            reader = new BufferedReader(new InputStreamReader(file
                    .getContents(), file.getCharset()));
            JSLintResult result = lint.lint(file.getFullPath().toString(),
                    reader);
            for (Issue issue : result.getIssues()) {
                addMarker(file, issue);
            }
        } catch (IOException e) {
View Full Code Here

Examples of com.googlecode.jslint4java.JSLint

        return jsLint;
    }

    /** Set up the current instance of JSLint using the current preferences. */
    public void configure() {
        JSLint lint = getJsLint();
        lint.resetOptions();
        IPreferencesService prefs = Platform.getPreferencesService();
        for (Option o : Option.values()) {
            String value = prefs.getString(JSLintPlugin.PLUGIN_ID, o.getLowerName(), null, null);
            if (value != null) {
                lint.addOption(o, value);
            }
        }
    }
View Full Code Here

Examples of org.pkg.jstools.JSLint

  /**
   * the command has been executed, so extract extract the needed information
   * from the application context.
   */
  public Object execute(ExecutionEvent event) throws ExecutionException {
    new JSLint().clearMarkers(ResourcesPlugin.getWorkspace().getRoot());
    return null;
  }
View Full Code Here

Examples of org.pkg.jstools.JSLint

    }

    if (activeEditor.isDirty()) {
      activeEditor.doSave(null);
    }
    new JSLint().validate(file);
   
    return null;
  }
View Full Code Here

Examples of ro.isdc.wro.extensions.processor.support.linter.JsLint

  /**
   * {@inheritDoc}
   */
  @Override
  protected AbstractLinter newLinter() {
    return new JsLint();
  }
View Full Code Here

Examples of ro.isdc.wro.extensions.processor.support.linter.JsLint

   *
   * @param options The lint options. Required.
   * @return A new JsLint processor.
   */
  public static ResourcePreProcessor jsLint(final LintOptions options) {
    return new LinterProcessor(new JsLint(), options);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.