Comments (6)
You are running gradle command in wrong directory, it is clear from error that settings.gradle
is not found in current directory.
Please step back to project root and run the gradle command.
Solution:
PS C:\Users\Zach\Documents\gmailListServ> gradle build
Error:
Project directory 'C:\Users\Zach\Documents\gmailListServ\src\main\java' is not part of the build defined by settings file 'C:\Users\Zach\Documents\gmailListServ\settings.gradle'. If this is an unrelated build, it must have its own settings file.
from java-samples.
Project directory 'C:\Users\Twine\AndroidStudioProjects\Travelinggs' is not part of the build defined by settings file 'C:\Users\Twine\AndroidStudioProjects\settings.gradle'. If this is an unrelated build, it must have its own settings file.
Help me out members
from java-samples.
From the error, looks like you've made changes. There's no project named gmailListServe in this repo.
Without additional information about what you did (e.g. what do your settings.gradle and build.gradle files look like) we can't provide any help.
from java-samples.
I'm getting The same error when I try to follow the procedure mentioned here https://developers.google.com/admin-sdk/directory/v1/quickstart/java
In my case this is the information that I have on the files that you mentioned
$ cat build.gradle
/*
- This file was generated by the Gradle 'init' task.
- This is a general purpose Gradle build.
- Learn how to create Gradle builds at https://guides.gradle.org/creating-new-gradle-builds/
*/
apply plugin: 'java'
apply plugin: 'application'
mainClassName = 'AdminSDKDirectoryQuickstart'
sourceCompatibility = 1.7
targetCompatibility = 1.7
version = '1.0'
repositories {
mavenCentral()
}
dependencies {
compile 'com.google.api-client:google-api-client:1.20.0'
compile 'com.google.oauth-client:google-oauth-client-jetty:1.20.0'
compile 'com.google.apis:google-api-services-admin-directory:directory_v1-rev53-1.20.0'
}
$cat settings.gradle
/*
- This file was generated by the Gradle 'init' task.
- The settings file is used to specify which projects to include in your build.
- Detailed information about configuring a multi-project build in Gradle can be found
- in the user manual at https://docs.gradle.org/5.4.1/userguide/multi_project_builds.html
*/
rootProject.name = 'AdminSDKDirectoryQuickstart'
what I'm trying to is use is the below command for the file AdminSDKDirectoryQuickstart.java
$gradle run
-
What went wrong:
Project directory '/home/user/Project/src/main/java' is not part of the build defined by settings file '/home/user/Project/settings.gradle'. If this is an unrelated build, it must have its own settings file. -
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. -
Get more help at https://help.gradle.org
BUILD FAILED in 0s
from java-samples.
@Tetrisman Let's follow up in issue #76.
from java-samples.
I also encountered a similar problem. The gradle file in the Android directory of the project is not generated by the setting.gradle configuration. What should I do if I change it
from java-samples.
Related Issues (20)
- Unable to set permissions for Windows File System HOT 1
- java.net.SocketException: Connection reset HOT 2
- Alert Center API Error: 401 Unauthorised
- 'compile' configuration introduced by the Java plugin have been deprecated since Gradle 4.10 HOT 2
- Dependency Dashboard
- Fix Typos in GmailQuickstart class comment
- Google Drive Class does not have drives API for shared drive management HOT 1
- Gmail API Java Quickstart Exception checkArgument(Preconditions.java:131) HOT 4
- Execution failed for task ':compileJava'. > warning: source release 18 requires target release 18
- Gmail API Cyrillic Support
- [SyncRepoSettings bot] - Invalid config file
- MyBusinessAPIs without user prompt HOT 1
- Google Drive Private File upload(config.json) HOT 2
- Java quickstart for Google Drive: java.net.BindException: Address already in use: bind HOT 1
- J
- Deleting a message gives GoogleJsonResponseException: Request had insufficient authentication scopes.
- tokens should be cleaned out by gradle at will HOT 1
- No export links available for google form and google map HOT 2
- In Sheets API - BatchUpdateValues should be able to update multiple ranges at a time.
- DOCUMENT HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from java-samples.