1

所以,已经在这个问题上苦苦挣扎了将近一个星期,现在正在尝试不同的事情,真的需要一点帮助。

因此,尝试编写一个非常简单的 Web 应用程序,它将使用 Google 电子表格作为源,这似乎应该是可能的,但我似乎无法让 grails 加载必要的类或库。

paridhi 在本文中提出了一种更简单的解决方案:http: //www.intelligrape.com/blog/2013/05/13/authentication-using-oauth-for-google-drive-application/

这似乎表明我应该做的(在编写所有代码之前)是将以下内容添加到 BuildConfig.groovy:

compile "com.google.gdata:core:1.47.1"
compile "com.google.apis:google-api-services-drive:v2-rev72-1.14.2-beta"
compile "com.google.http-client:google-http-client-jackson:1.14.1-beta"

摆弄之后,我尝试重新安装 GG,创建了一个新项目,并且只将这些行添加到 BuildConfig.groovy,我得到的只是依赖构建错误。

> objc[1450]: Class JavaLaunchHelper is implemented in both /Library/Java/JavaVirtualMachines/jdk1.7.0_40.jdk/Contents/Home/bin/java and /Library/Java/JavaVirtualMachines/jdk1.7.0_40.jdk/Contents/Home/jre/lib/libinstrument.dylib. One of the two will be used. Which one is undefined.
| Loading Grails 2.2.4
| Configuring classpath
:: problems summary ::
:::: WARNINGS
        [FAILED     ] com.google.gdata#core;1.47.1!core.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.gdata/core/jars/core-1.47.1.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.gdata/core/bundles/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/core-1.47.1.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-core/tags/RELEASE_1.47.1/grails-core-1.47.1.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/gdata/core/1.47.1/core-1.47.1.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/gdata/core/1.47.1/core-1.47.1.zip
        [FAILED     ] com.google.apis#google-api-services-drive;v2-rev72-1.14.2-beta!google-api-services-drive.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.apis/google-api-services-drive/jars/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.apis/google-api-services-drive/bundles/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-google-api-services-drive/tags/RELEASE_v2-rev72-1.14.2-beta/grails-google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/apis/google-api-services-drive/v2-rev72-1.14.2-beta/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/apis/google-api-services-drive/v2-rev72-1.14.2-beta/google-api-services-drive-v2-rev72-1.14.2-beta.zip
        [FAILED     ] com.google.http-client#google-http-client-jackson;1.14.1-beta!google-http-client-jackson.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.http-client/google-http-client-jackson/jars/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.http-client/google-http-client-jackson/bundles/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-google-http-client-jackson/tags/RELEASE_1.14.1-beta/grails-google-http-client-jackson-1.14.1-beta.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/http-client/google-http-client-jackson/1.14.1-beta/google-http-client-jackson-1.14.1-beta.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/http-client/google-http-client-jackson/1.14.1-beta/google-http-client-jackson-1.14.1-beta.zip
        ::::::::::::::::::::::::::::::::::::::::::::::
        ::              FAILED DOWNLOADS            ::
        :: ^ see resolution messages for details  ^ ::
        ::::::::::::::::::::::::::::::::::::::::::::::
        :: com.google.gdata#core;1.47.1!core.zip
        :: com.google.apis#google-api-services-drive;v2-rev72-1.14.2-beta!google-api-services-drive.zip
        :: com.google.http-client#google-http-client-jackson;1.14.1-beta!google-http-client-jackson.zip
        ::::::::::::::::::::::::::::::::::::::::::::::
:: problems summary ::
:::: WARNINGS
        [FAILED     ] com.google.gdata#core;1.47.1!core.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.gdata/core/jars/core-1.47.1.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.gdata/core/bundles/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/core-1.47.1.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-core/tags/RELEASE_1.47.1/grails-core-1.47.1.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/gdata/core/1.47.1/core-1.47.1.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/gdata/core/1.47.1/core-1.47.1.zip
        [FAILED     ] com.google.apis#google-api-services-drive;v2-rev72-1.14.2-beta!google-api-services-drive.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.apis/google-api-services-drive/jars/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.apis/google-api-services-drive/bundles/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-google-api-services-drive/tags/RELEASE_v2-rev72-1.14.2-beta/grails-google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/apis/google-api-services-drive/v2-rev72-1.14.2-beta/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/apis/google-api-services-drive/v2-rev72-1.14.2-beta/google-api-services-drive-v2-rev72-1.14.2-beta.zip
        [FAILED     ] com.google.http-client#google-http-client-jackson;1.14.1-beta!google-http-client-jackson.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.http-client/google-http-client-jackson/jars/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.http-client/google-http-client-jackson/bundles/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-google-http-client-jackson/tags/RELEASE_1.14.1-beta/grails-google-http-client-jackson-1.14.1-beta.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/http-client/google-http-client-jackson/1.14.1-beta/google-http-client-jackson-1.14.1-beta.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/http-client/google-http-client-jackson/1.14.1-beta/google-http-client-jackson-1.14.1-beta.zip
        ::::::::::::::::::::::::::::::::::::::::::::::
        ::              FAILED DOWNLOADS            ::
        :: ^ see resolution messages for details  ^ ::
        ::::::::::::::::::::::::::::::::::::::::::::::
        :: com.google.gdata#core;1.47.1!core.zip
        :: com.google.apis#google-api-services-drive;v2-rev72-1.14.2-beta!google-api-services-drive.zip
        :: com.google.http-client#google-http-client-jackson;1.14.1-beta!google-http-client-jackson.zip
        ::::::::::::::::::::::::::::::::::::::::::::::
:: problems summary ::
:::: WARNINGS
        [FAILED     ] com.google.gdata#core;1.47.1!core.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/core-1.47.1.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.gdata/core/jars/core-1.47.1.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.gdata/core/bundles/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/core-1.47.1.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/core-1.47.1.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-core/tags/RELEASE_1.47.1/grails-core-1.47.1.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/gdata/core/1.47.1/core-1.47.1.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/gdata/core/1.47.1/core-1.47.1.zip
        [FAILED     ] com.google.apis#google-api-services-drive;v2-rev72-1.14.2-beta!google-api-services-drive.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.apis/google-api-services-drive/jars/google-api-services-drive-v2-rev72-1.14.2-beta.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.apis/google-api-services-drive/bundles/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-google-api-services-drive/tags/RELEASE_v2-rev72-1.14.2-beta/grails-google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/apis/google-api-services-drive/v2-rev72-1.14.2-beta/google-api-services-drive-v2-rev72-1.14.2-beta.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/apis/google-api-services-drive/v2-rev72-1.14.2-beta/google-api-services-drive-v2-rev72-1.14.2-beta.zip
        [FAILED     ] com.google.http-client#google-http-client-jackson;1.14.1-beta!google-http-client-jackson.zip:  (0ms)
    ==== grailsPlugins: tried
      /Users/bengtbjorkberg/Documents/grails-work/crTest/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/cache-1.0.1/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/database-migration-1.3.2/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/hibernate-2.2.4/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/jquery-1.8.3/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/resources-1.2/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/tomcat-2.2.4/lib/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/.grails/2.2.4/projects/crTest/plugins/webxml-1.4.1/lib/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.http-client/google-http-client-jackson/jars/google-http-client-jackson-1.14.1-beta.zip
      /Users/bengtbjorkberg/springsource/grails-2.2.4/lib/com.google.http-client/google-http-client-jackson/bundles/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/src/libs/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/dist/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/.grails/2.2.4/cached-installed-plugins/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsHome: tried
      /Users/bengtbjorkberg/springsource/grails-2.2.4/plugins/google-http-client-jackson-1.14.1-beta.zip
    ==== grailsCentral: tried
      http://grails.org/plugins/grails-google-http-client-jackson/tags/RELEASE_1.14.1-beta/grails-google-http-client-jackson-1.14.1-beta.zip
    ==== localMavenResolver: tried
      /Users/bengtbjorkberg/.m2/repository/com/google/http-client/google-http-client-jackson/1.14.1-beta/google-http-client-jackson-1.14.1-beta.zip
    ==== mavenCentral: tried
      http://repo1.maven.org/maven2/com/google/http-client/google-http-client-jackson/1.14.1-beta/google-http-client-jackson-1.14.1-beta.zip
        ::::::::::::::::::::::::::::::::::::::::::::::
        ::              FAILED DOWNLOADS            ::
        :: ^ see resolution messages for details  ^ ::
        ::::::::::::::::::::::::::::::::::::::::::::::
        :: com.google.gdata#core;1.47.1!core.zip
        :: com.google.apis#google-api-services-drive;v2-rev72-1.14.2-beta!google-api-services-drive.zip
        :: com.google.http-client#google-http-client-jackson;1.14.1-beta!google-http-client-jackson.zip
        ::::::::::::::::::::::::::::::::::::::::::::::
| Error Failed to resolve dependencies (Set log level to 'warn' in BuildConfig.groovy for more information):
- com.google.gdata:core:1.47.1
- com.google.apis:google-api-services-drive:v2-rev72-1.14.2-beta
- com.google.http-client:google-http-client-jackson:1.14.1-beta

=============================== 编辑=================== ================= 好像我把它添加到了错误的部分,现在我得到了一个关于 jsr 305 的稍微不同的问题

Seems like it, now I have another issue, where can I get jsr305 (think that is what it is asking for ....:: problems summary ::
:::: WARNINGS
        ::::::::::::::::::::::::::::::::::::::::::::::
        ::          UNRESOLVED DEPENDENCIES         ::
        ::::::::::::::::::::::::::::::::::::::::::::::
        :: com.google.code.findbugs#jsr305;1.3.9: configuration not found in com.google.code.findbugs#jsr305;1.3.9: 'compile'. It was required from com.google.http-client#google-http-client;1.14.1-beta compile
        ::::::::::::::::::::::::::::::::::::::::::::::
:: problems summary ::
:::: WARNINGS
        ::::::::::::::::::::::::::::::::::::::::::::::
        ::          UNRESOLVED DEPENDENCIES         ::
        ::::::::::::::::::::::::::::::::::::::::::::::
        :: com.google.code.findbugs#jsr305;1.3.9: configuration not found in com.google.code.findbugs#jsr305;1.3.9: 'compile'. It was required from com.google.http-client#google-http-client;1.14.1-beta compile
        ::::::::::::::::::::::::::::::::::::::::::::::
:: problems summary ::
:::: WARNINGS
        ::::::::::::::::::::::::::::::::::::::::::::::
        ::          UNRESOLVED DEPENDENCIES         ::
        ::::::::::::::::::::::::::::::::::::::::::::::
        :: com.google.code.findbugs#jsr305;1.3.9: configuration not found in com.google.code.findbugs#jsr305;1.3.9: 'compile'. It was required from com.google.http-client#google-http-client;1.14.1-beta compile
        ::::::::::::::::::::::::::::::::::::::::::::::
| Error Failed to resolve dependencies (Set log level to 'warn' in BuildConfig.groovy for more information):
- com.google.code.findbugs:jsr305:1.3.9

==================================编辑2 =============== =========================== 谢谢所有帮助过的人,似乎只是正确地导入了jre。所以如果有人有同样的问题。你需要做两件事。

添加到 BuildConfig.grove(在依赖项下)

compile "com.google.code.findbugs:jsr305:1.3.9"
compile "com.google.gdata:core:1.47.1"
compile "com.google.apis:google-api-services-drive:v2-rev72-1.14.2-beta"
compile "com.google.http-client:google-http-client-jackson:1.14.1-beta"

接下来,为您的控制器添加正确的导入行

import com.google.api.client.googleapis.auth.oauth2.*

我的最后一个问题是 eclipse 似乎仍然不喜欢 GoogleAuthorizationCodeRequestUrlbut 编译好。希望这对某人有所帮助,再次感谢 tim_yates

4

0 回答 0