Skip to content

Conversation

@raybell-md
Copy link
Contributor

@raybell-md raybell-md commented Jan 27, 2026

Fixes #158

…rives` and `includeItemsFromAllDrives` parameters in Drive API calls.
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @raybell-md, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces functionality to interact with Google Shared Drives. It achieves this by modifying existing Google Drive API calls within the DriveService to include specific parameters that enable access to and manipulation of Shared Drive content. The changes are accompanied by updated and new unit tests to ensure the correct application of these parameters.

Highlights

  • Google Shared Drive Support: Implemented support for Google Shared Drives by adding supportsAllDrives: true and includeItemsFromAllDrives: true parameters to relevant Google Drive API calls.
  • API Call Modifications: Modified files.list, files.create, and files.get methods within DriveService to include the necessary parameters for interacting with Shared Drives.
  • Unit Test Enhancements: Updated existing unit tests and added new test cases to verify that the Google Drive API calls correctly include the supportsAllDrives and includeItemsFromAllDrives flags, ensuring proper functionality with Shared Drives.
  • Dependency Metadata Update: Updated package-lock.json to include peer: true for several development dependencies, likely reflecting an update to the dependency tree or a change in how peer dependencies are managed.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

The pull request successfully implements support for Google Shared Drives by adding the supportsAllDrives and includeItemsFromAllDrives parameters to the relevant Google Drive API calls in DriveService.ts. The accompanying test file, DriveService.test.ts, has been appropriately updated with new test cases and assertions to validate this new functionality. The changes are well-aligned with the stated objective of the pull request.

@raybell-md
Copy link
Contributor Author

raybell-md commented Jan 27, 2026

something not right but can't work out what. Getting getting ✕ MCP ERROR (google-workspace) when testing.
Looks like auth not showing up
(#30 (comment))

@raybell-md
Copy link
Contributor Author

Other that it acting weird with OAuth when testing once I fixed that it worked as expected.

Ready for review

@raybell-md raybell-md changed the title WIP: feat: Add support for Google Shared Drives by including supportsAllDrives and includeItemsFromAllDrives parameters in Drive API calls. feat: Add support for Google Shared Drives by including supportsAllDrives and includeItemsFromAllDrives parameters in Drive API calls. Jan 27, 2026

mockDriveAPI.files.get.mockImplementation((params: any) => {
if (params.alt === 'media') {
return Promise.resolve({

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: unrelated

});
}
return Promise.resolve({
data: { id: mockFileId, name: 'test.txt', mimeType: 'text/plain' },

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unrelated nit

q = "sharedWithMe";
}
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

logToFile(`Downloading Drive file ${fileId} to ${localPath}`);
try {
const drive = await this.getDriveClient();

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

}

if (mimeType.includes('vnd.google-apps.')) {
return {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

// 3. Save to localPath
const absolutePath = path.isAbsolute(localPath) ? localPath : path.resolve(PROJECT_ROOT, localPath);
const dir = path.dirname(absolutePath);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

@Prakul95
Copy link

Prakul95 commented Jan 28, 2026

I think your changes should be added to docs, sheets and slides search as well

Revert indentation nits in DriveService
@raybell-md
Copy link
Contributor Author

raybell-md commented Jan 28, 2026

Thanks @Prakul95 reverted the nits. I also opened #180 as it can help avoid AI fixing this on every PR

@raybell-md
Copy link
Contributor Author

I think your changes should be added to docs, sheets and slides search as well

Probably. Want to open an issue? I like small PRs and don't want to include those in this one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

drive_search tool has limitations with Google Drive Shared Drives

2 participants