问题
I am learning Adobe CQ5 on my own. I had pulled the folder structure of jcr_root to my eclipse workbench using vaultclipse. Now my request is can someone provide me some references wherein I can write a hello world bundle in eclipse, bundle it and then push the jar file onto CRX.? To be simple, Steps to achieve a working bundle on CRX which we have created on eclipse environment.
What ever I have been through the reference links of Adobe CQ5 blogs, I see most of them are on CRXDE environment rather than eclipse environment.
回答1:
I'd prefer you to use Eclipse IDE or InteliJ IDEA. For exlipse: Use maven command on bundle's pom.xml file
- rightclick on pom.xml file of bundle.
- Run as.
- Run configurations.
- In Base derictory field browse package of your bundle.
In Goals field put:
install org.apache.sling:maven-sling-plugin:install -Dsling.url=http://SERVERNAME/system/console/install -Dsling.user=admin -Dsling.password=admin
Press Run button
and yours bundle will be installed to CRX
You can check if bundle installed using link
http://SERVENAME/system/console/bundles
来源:https://stackoverflow.com/questions/28391840/create-a-hello-world-bundle-in-eclipse-and-check-the-working-jar-file-on-crx