2
Groovy 파일의 시작 부분에 @GrabResolver(name='restlet', root='http://maven.restlet.org/')
을 사용할 수 있다는 것을 알고 있습니다. 그러나 나는 groovysh에있는 동안이 전화를 할 수 있기를 바란다.groovysh에서 원격 저장소를 사용하기 위해 GrabResolver를 사용하는 방법
이 방법이 있습니까?
Groovy 파일의 시작 부분에 @GrabResolver(name='restlet', root='http://maven.restlet.org/')
을 사용할 수 있다는 것을 알고 있습니다. 그러나 나는 groovysh에있는 동안이 전화를 할 수 있기를 바란다.groovysh에서 원격 저장소를 사용하기 위해 GrabResolver를 사용하는 방법
이 방법이 있습니까?
groovy:000> import groovy.grape.Grape
===> [import groovy.grape.Grape]
groovy:000> Grape.addResolver(name:'restlet', root:'http://maven.restlet.org/')
===> null
@GrabResolver
내부적 주석이 사용되는 클래스에 상기 통화 (Grape.addResolver()
)를 추가한다. 기본적으로이 동작은 initClass
속성이 주석에서 true로 설정되어 구동됩니다.