When I started to play with geb in groovy shell.
You can pull the required dependencies via groovy grape as:
groovy.grape.Grape.grab([group:'org.gebish', module:'geb-core', version:'0.9.2'])
groovy.grape.Grape.grab([group:'org.seleniumhq.selenium', module:'selenium-chrome-driver', version:'2.37.1'])
groovy.grape.Grape.grab([group:'org.seleniumhq.selenium', module:'selenium-support', version:'2.37.1'])
but i faced the following error:
groovy:000> groovy.grape.Grape.grab([group:'org.seleniumhq.selenium', module:'selenium-chrome-driver', version:'2.37.1'])
ERROR java.lang.RuntimeException:
Error grabbing Grapes -- [download failed: cglib#cglib-nodep;2.1_3!cglib-nodep.jar]
at groovysh_evaluate.run (groovysh_evaluate:2)
It turned out the the 2.1_3
version of cglib-nodep was removed from central maven repo. But luckily you can still find it in the ibiblio mirror
. You can customize the list of maven reposed used by grape by creating a ~/.groovy/grapeConfig.xml
file.
You can download the fixxing version from this gist:
curl -o ~/.groovy/grapeConfig.xml https://gist.githubusercontent.com/lalyos/9366690/raw/grapeConfig.xml