Skip to content

docs: add Windows PowerShell equivalents for environments and scripting#20333

Merged
scidomino merged 1 commit intomainfrom
tomm_win_docs
Feb 27, 2026
Merged

docs: add Windows PowerShell equivalents for environments and scripting#20333
scidomino merged 1 commit intomainfrom
tomm_win_docs

Conversation

@scidomino
Copy link
Collaborator

@scidomino scidomino commented Feb 25, 2026

Summary

Standardizes Gemini CLI documentation for Windows users by adding PowerShell equivalents for environment variables, file system operations, and scripting.

Details

  • Environment Variables: Added PowerShell syntax ($env:VAR = "val") alongside POSIX export for all environment variable configuration examples.
  • Tutorial Setup: Provided PowerShell alternatives for directory creation (mkdir -p -> New-Item) and file operations in the Automation, Hooks, and Skills tutorials.
  • Scripting Consistency: Updated cross-platform scripting scenarios to show both Bash and PowerShell implementations.
  • Pathing: Ensured Windows examples use correct NT-style paths (e.g., C:\ProgramData) where appropriate.

Related Issues

Fixes #17138

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @scidomino, 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 significantly enhances the Gemini CLI documentation by integrating comprehensive Windows PowerShell equivalents for various commands, environment variable settings, and scripting examples. The changes aim to provide a more consistent and user-friendly experience for Windows users, ensuring that all key functionalities are clearly demonstrated with appropriate PowerShell syntax and conventions. This update improves cross-platform usability and clarifies setup procedures for different operating systems.

Highlights

  • Shell Standardization: Standardized on PowerShell for all Windows-specific shell examples, removing legacy Command Prompt (CMD) instructions to align with the CLI's internal execution environment.
  • Environment Variables: Added PowerShell syntax ($env:VAR = "val") alongside POSIX export for all environment variable configuration examples across the documentation.
  • Tutorial Setup: Provided PowerShell alternatives for directory creation (mkdir -p -> New-Item) and file operations in the Automation, Hooks, and Skills tutorials.
  • Scripting Consistency: Updated cross-platform scripting scenarios to show both Bash and PowerShell implementations, including full script examples.
  • Pathing: Ensured Windows examples use correct NT-style paths (e.g., C:\ProgramData) where appropriate.
Changelog
  • docs/cli/cli-reference.md
    • Added PowerShell equivalent for the cat file | gemini command example.
  • docs/cli/custom-commands.md
    • Added PowerShell commands for creating custom command directories and TOML files.
  • docs/cli/enterprise.md
    • Added PowerShell profile alternative for setting system settings path.
    • Included PowerShell examples for isolating state using GEMINI_CLI_HOME.
  • docs/cli/sandbox.md
    • Added PowerShell examples for configuring sandboxing via GEMINI_SANDBOX environment variable.
    • Included PowerShell equivalents for SANDBOX_FLAGS and SANDBOX_SET_UID_GID environment variables.
  • docs/cli/telemetry.md
    • Added PowerShell equivalents for setting OTLP_GOOGLE_CLOUD_PROJECT and GOOGLE_CLOUD_PROJECT environment variables.
    • Included PowerShell syntax for GOOGLE_APPLICATION_CREDENTIALS.
  • docs/cli/tutorials/automation.md
    • Added PowerShell equivalent for piping file content (Get-Content).
    • Provided full PowerShell script (generate_docs.ps1) for generating documentation.
    • Included full PowerShell script (generate_json.ps1) for extracting structured data.
    • Added PowerShell function for the 'Smart Commit' alias (gcommit).
  • docs/cli/tutorials/mcp-setup.md
    • Added PowerShell example for setting the GITHUB_PERSONAL_ACCESS_TOKEN environment variable.
  • docs/cli/tutorials/skills-getting-started.md
    • Added PowerShell command for creating skill directories.
  • docs/extensions/writing-extensions.md
    • Added PowerShell commands for creating custom command directories.
    • Added PowerShell commands for creating skill directories.
  • docs/get-started/authentication.md
    • Added PowerShell examples for setting GEMINI_API_KEY, GOOGLE_CLOUD_PROJECT, and GOOGLE_CLOUD_LOCATION.
    • Included PowerShell commands for unsetting GOOGLE_API_KEY and GEMINI_API_KEY.
    • Added PowerShell syntax for GOOGLE_APPLICATION_CREDENTIALS.
    • Updated .env file creation instructions with PowerShell examples.
  • docs/get-started/installation.md
    • Updated supported shells to explicitly include PowerShell.
  • docs/hooks/best-practices.md
    • Added PowerShell examples for manually testing hook scripts.
    • Included notes on PowerShell script execution policies and executability.
  • docs/hooks/writing-hooks.md
    • Added PowerShell script example for creating hook directories and logging tools.
  • docs/ide-integration/index.md
    • Added PowerShell example for setting the GEMINI_CLI_IDE_PID environment variable.
  • docs/reference/configuration.md
    • Updated environment variable descriptions to include PowerShell syntax examples for GEMINI_MODEL, GEMINI_CLI_HOME, GOOGLE_API_KEY, GOOGLE_CLOUD_PROJECT, GOOGLE_APPLICATION_CREDENTIALS, GOOGLE_GENAI_API_VERSION, OTLP_GOOGLE_CLOUD_PROJECT, and GOOGLE_CLOUD_LOCATION.
  • docs/reference/policy-engine.md
    • Added PowerShell command for creating policy directories.
  • docs/resources/faq.md
    • Added PowerShell example for setting the GOOGLE_CLOUD_PROJECT environment variable.
  • docs/resources/troubleshooting.md
    • Added PowerShell examples for NODE_USE_SYSTEM_CA and NODE_EXTRA_CA_CERTS environment variables.
Activity
  • No human activity has been recorded on this pull request yet.
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

This pull request significantly improves the documentation for Windows users by adding PowerShell equivalents for shell commands, environment variable settings, and scripting examples across multiple documents. The changes are thorough, consistent in their technical implementation, and use idiomatic PowerShell, making the Gemini CLI much more accessible on Windows. The addition of notes regarding PowerShell-specific concepts like execution policies is particularly helpful. The overall quality of the documentation is greatly enhanced by these additions.

@github-actions
Copy link

github-actions bot commented Feb 25, 2026

Size Change: -2 B (0%)

Total Size: 25.8 MB

ℹ️ View Unchanged
Filename Size Change
./bundle/gemini.js 25.3 MB -2 B (0%)
./bundle/node_modules/@google/gemini-cli-devtools/dist/client/main.js 221 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/_client-assets.js 227 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/index.js 11.5 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/types.js 132 B 0 B
./bundle/sandbox-macos-permissive-open.sb 890 B 0 B
./bundle/sandbox-macos-permissive-proxied.sb 1.31 kB 0 B
./bundle/sandbox-macos-restrictive-open.sb 3.36 kB 0 B
./bundle/sandbox-macos-restrictive-proxied.sb 3.56 kB 0 B
./bundle/sandbox-macos-strict-open.sb 4.82 kB 0 B
./bundle/sandbox-macos-strict-proxied.sb 5.02 kB 0 B

compressed-size-action

@gemini-cli gemini-cli bot added the area/core Issues related to User Interface, OS Support, Core Functionality label Feb 25, 2026
@scidomino scidomino force-pushed the tomm_win_docs branch 2 times, most recently from b516f04 to 9781abb Compare February 25, 2026 20:10
@scidomino scidomino marked this pull request as ready for review February 25, 2026 20:11
@scidomino scidomino requested review from a team as code owners February 25, 2026 20:11
@jkcinouye jkcinouye self-assigned this Feb 26, 2026
@scidomino scidomino requested a review from jkcinouye February 26, 2026 20:54
Copy link
Contributor

@jkcinouye jkcinouye left a comment

Choose a reason for hiding this comment

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

LGTM but I do wonder if some of these lengthier ones are eventually going to need to be separated into multiple docs. A problem for the future!

@scidomino scidomino added this pull request to the merge queue Feb 27, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 27, 2026
@scidomino scidomino added this pull request to the merge queue Feb 27, 2026
Merged via the queue into main with commit c89d4f9 Feb 27, 2026
26 of 27 checks passed
@scidomino scidomino deleted the tomm_win_docs branch February 27, 2026 23:53
BryanBradfo pushed a commit to BryanBradfo/gemini-cli that referenced this pull request Mar 5, 2026
liamhelmer pushed a commit to badal-io/gemini-cli that referenced this pull request Mar 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/core Issues related to User Interface, OS Support, Core Functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Widows Specific Documentation & Onboarding

2 participants