Code Monkey home page Code Monkey logo

chutch / cq-groovy-console Goto Github PK

View Code? Open in Web Editor NEW

This project forked from icfnext/aem-groovy-console

0.0 0.0 0.0 3.18 MB

The AEM Groovy Console provides an interface for running Groovy scripts in the AEM (Adobe CQ) container. Scripts can be created to manipulate content in the JCR, call OSGi services, or execute arbitrary code using the CQ, Sling, or JCR APIs.

License: Other

Java 13.21% CSS 6.84% JavaScript 37.88% Groovy 42.07%

cq-groovy-console's Introduction

AEM Groovy Console

CITYTECH, Inc.

Overview

The AEM Groovy Console provides an interface for running Groovy scripts in the AEM (Adobe CQ) container. Scripts can be created to manipulate content in the JCR, call OSGi services, or execute arbitrary code using the AEM, Sling, or JCR APIs. After installing the package in AEM (instructions below), see the console page for documentation on the available bindings and methods. Sample scripts are included in the package for reference.

Screenshot

Requirements

  • AEM 6.1 running on localhost:4502
  • Versions 7.x.x are compatible with AEM 6.0
  • Versions 5.x.x and 6.x.x are compatible with CQ 5.6
  • Versions 3.x.x are compatible with CQ 5.4 and 5.5
  • Maven 3.x

Installation

  1. Download the console package. For previous versions, tags can be checked out from GitHub and built directly from the source (e.g. mvn install).

  2. Verify the installation.

Additional build profiles may be added in the project's pom.xml to support deployment to non-localhost AEM servers.

AEM 6.0 no longer allows vanity paths for pages in /etc by default. To enable access to the Groovy Console from /groovyconsole as in previous versions, the Apache Sling Resource Resolver Factory OSGi configuration must be updated to allow vanity paths from /etc. The Groovy Console Configuration Service can then be updated to enable the vanity path if so desired.

Context Path Support

If you are running AEM with a context path, set the Maven property aem.context.path during installation.

mvn install -P local -Daem.context.path=/context

Extensions

Starting in version 7.0.0, the Groovy Console provides extension hooks to further customize script execution. The console exposes an API containing three extension provider interfaces that can be implemented as OSGi services in any bundle deployed to an AEM instance. See the default extension providers in the com.citytechinc.aem.groovy.console.extension.impl package for examples of how a bundle can implement these services to supply additional script bindings, metaclasses, and star imports.

Notifications

To provide custom notifications for script executions, bundles may implement the com.citytechinc.aem.groovy.console.notification.NotificationService interface (see the com.citytechinc.aem.groovy.console.notification.impl.EmailNotificationService class for an example). These services will be dynamically bound by the Groovy Console service and all registered notification services will be called for each script execution.

Notes

Sample scripts can be found in the src/main/scripts directory.

Versioning

Follows Semantic Versioning guidelines.

cq-groovy-console's People

Contributors

bryanw avatar christianvozar avatar kairas avatar kitarek avatar markdaugherty avatar mszu avatar paul-bjorkstrand avatar steeleforge avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.