Please communicate the following information to Gemini, the prototyper, in advance. Please also provide Gemini with a development preview UR
Please communicate the following information to the prototyper, Gemini, in advance. Please also provide the development preview URL to the prototyper, Gemini, in advance.
Firebase Studio Development Environment Workflow and Knowledge
This document summarizes the knowledge required for AI development partners (App Prototypers) to understand the characteristics of this development environment and work smoothly with users.
1. Terminal and Command Execution
Available Command Line Tools
The following main commands are available in the terminal of this environment.
git: Version controlgcloud: Google Cloud resource operationsfirebase: Firebase project operations
How to Execute Commands
In dialogue with the user, the AI presents commands to be executed.
`bashMarkdown: When commands are presented in this format, an execute button (▶) appears in the user interface. The user can execute the command simply by pressing this button.- AI Cannot Execute Directly: The AI itself does not have the permission to execute commands directly. The basic workflow is a collaborative one: the user executes a command, communicates the results to the AI, and then proceeds to the next step.
2. Deployment and URL
Deployment Flow
- Pushing to Production: By pressing the "Publish" button in the upper right corner of the UI, the developed application is deployed to Firebase App Hosting and pushed to the production environment.
Environment URL
- AI Doesn't Know URLs: By default, the AI does not know the development preview URL or the production URL.
- User-Provided Information: The user can run a command such as
firebase apphosting:backends:listand provide the AI with the URL identified from the command. The AI can then remember that information as context and use it for future development (such as CORS configuration). - Example of URL confirmed:
- Preview URL:
https://9000-firebase-studio-*.cloudworkstations.dev/ - Production URL: URL confirmed using the
firebase apphosting:backends:listcommand
3. Infrastructure Configuration Workflow Example
In addition to code, Firebase and Google Cloud infrastructure configuration can also be performed in conjunction with AI.
- User specifies the goal: (Example: "I want to securely set the service account's private key as an environment variable.")
- AI plans and suggests commands:
- Check the account with
gcloud iam service-accounts list. - Use
gcloud iam service-accounts keys create - ...to output the key to standard output without saving it to a file. - User executes command: Executes the suggested command and optionally provides feedback to the AI with the results.
- Continuous Operation Through Collaboration: The AI suggests the next step based on feedback.
This workflow allows users unfamiliar with commands to safely and accurately configure infrastructure with the assistance of the AI.
4. Version Control (Git) Workflow Example
How Auto-Commit Works
The AI suggests file changes, and once they're applied, the changes are automatically committed to Git. The commit message contains the AI's instructions (user prompts).
Reverting to a Specific Commit
You can also revert a project to a specific past state through interaction with the AI.
- AI suggests a history check command: The AI suggests a command such as
git log --oneline. - User executes a command and shares the results: The user executes a command and shares the displayed commit history with the AI.
- User specifies the commit to revert to: The user identifies the commit in the history to which they want to revert.
- AI suggests a rollback command: The AI suggests a command to return to a specified state, such as
git reset --hard <commit ID>. - User executes a command: The user executes the command, reverting the project's files to a previous version.
I would like to see the prototyper gemini be able to execute terminal commands directly.
I would appreciate your consideration.