debian-mirror-gitlab/doc/user/project/web_ide/index.md

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

206 lines
8.1 KiB
Markdown
Raw Normal View History

2020-10-24 23:57:45 +05:30
---
stage: Create
2023-06-20 00:43:36 +05:30
group: IDE
2022-11-25 23:54:43 +05:30
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/product/ux/technical-writing/#assignments
2020-10-24 23:57:45 +05:30
---
2021-03-11 19:13:27 +05:30
# Web IDE **(FREE)**
2018-05-09 12:01:36 +05:30
2023-07-09 08:55:56 +05:30
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/95169) in GitLab 15.7 [with a flag](../../../administration/feature_flags.md) named `vscode_web_ide`. Disabled by default.
> - [Enabled on GitLab.com](https://gitlab.com/gitlab-org/gitlab/-/issues/371084) in GitLab 15.7.
> - [Enabled on self-managed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/115741) in GitLab 15.11.
2021-01-29 00:20:46 +05:30
2023-07-09 08:55:56 +05:30
FLAG:
On self-managed GitLab, by default this feature is available. To hide the feature, ask an administrator to [disable the feature flag](../../../administration/feature_flags.md) named `vscode_web_ide`. On GitLab.com, this feature is available.
2021-01-29 00:20:46 +05:30
2023-07-09 08:55:56 +05:30
The Web IDE is an advanced editor with commit staging.
You can use the Web IDE to make changes to multiple files directly from the GitLab UI.
For a more basic implementation, see [Web Editor](../repository/web_editor.md).
2019-02-15 15:39:39 +05:30
2023-07-09 08:55:56 +05:30
To pair the Web IDE with a remote development environment, see [remote development](../remote_development/index.md).
2020-07-28 23:09:34 +05:30
2023-07-09 08:55:56 +05:30
## Use the Web IDE
2019-02-15 15:39:39 +05:30
2023-07-09 08:55:56 +05:30
To open the Web IDE from the GitLab UI:
2020-11-24 15:15:51 +05:30
2023-07-09 08:55:56 +05:30
1. On the top bar, select **Main menu > Projects** and find your project.
1. Use the <kbd>.</kbd> keyboard shortcut.
2020-11-24 15:15:51 +05:30
2023-07-09 08:55:56 +05:30
You can also open the Web IDE from:
2020-11-24 15:15:51 +05:30
2023-07-09 08:55:56 +05:30
- A file
- The repository file list
- A merge request
2020-11-24 15:15:51 +05:30
2023-07-09 08:55:56 +05:30
### From a file or the repository file list
2021-04-29 21:17:54 +05:30
2023-07-09 08:55:56 +05:30
To open the Web IDE from a file or the repository file list:
2021-04-29 21:17:54 +05:30
2023-07-09 08:55:56 +05:30
- In the upper-right corner of the page, select **Open in Web IDE**.
2020-10-24 23:57:45 +05:30
2023-07-09 08:55:56 +05:30
If **Open in Web IDE** is not visible:
2020-10-24 23:57:45 +05:30
2023-07-09 08:55:56 +05:30
1. Next to **Edit** or **Gitpod**, select the down arrow (**{chevron-lg-down}**).
1. From the dropdown list, select **Open in Web IDE**.
1. Select **Open in Web IDE**.
2020-10-24 23:57:45 +05:30
2023-07-09 08:55:56 +05:30
### From a merge request
2020-10-24 23:57:45 +05:30
2023-07-09 08:55:56 +05:30
To open the Web IDE from a merge request:
2020-11-24 15:15:51 +05:30
2023-07-09 08:55:56 +05:30
1. Go to your merge request.
1. In the upper-right corner, select **Code > Open in Web IDE**.
2020-05-24 23:13:21 +05:30
2023-07-09 08:55:56 +05:30
The Web IDE opens new and modified files in separate tabs and displays changes side by side with the original source.
To optimize loading time, only the top 10 files (by number of lines changed) are opened automatically.
2020-05-24 23:13:21 +05:30
2023-07-09 08:55:56 +05:30
In the file tree, any new or modified file in the merge request is indicated by an icon next to the filename.
To view changes to a file, right-click the filename and select **Compare with merge request base**.
2020-05-24 23:13:21 +05:30
2023-07-09 08:55:56 +05:30
## Open a file in the Web IDE
2020-05-24 23:13:21 +05:30
2023-07-09 08:55:56 +05:30
To open any file by its name:
2020-11-24 15:15:51 +05:30
2023-07-09 08:55:56 +05:30
1. Press <kbd>Command</kbd>+<kbd>P</kbd>.
1. Enter the name of your file.
2020-05-24 23:13:21 +05:30
2023-07-09 08:55:56 +05:30
![fuzzy_finder_v15_7](img/fuzzy_finder_v15_7.png)
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
## Search across files
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
You can use the Web IDE to search all files in the opened folder.
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
To search across files:
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
1. Press <kbd>Shift</kbd>+<kbd>Command</kbd>+<kbd>F</kbd>.
1. Enter your search term.
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
In the Web IDE, only partial results from opened files are displayed.
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
## View a list of changed files
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
To view a list of files you changed in the Web IDE:
2018-05-09 12:01:36 +05:30
2023-07-09 08:55:56 +05:30
- On the activity bar on the left, select **Source Control**,
or press <kbd>Control</kbd>+<kbd>Shift</kbd>+<kbd>G</kbd>.
2019-12-04 20:38:33 +05:30
2023-07-09 08:55:56 +05:30
Your `CHANGES`, `STAGED CHANGES`, and `MERGE CHANGES` are displayed.
For more information, see the [VS Code documentation](https://code.visualstudio.com/docs/sourcecontrol/overview#_commit).
2020-04-08 14:13:33 +05:30
2023-07-09 08:55:56 +05:30
## Upload a new file
2018-05-09 12:01:36 +05:30
2023-07-09 08:55:56 +05:30
To upload a new file and add it to the Git repository:
2018-05-09 12:01:36 +05:30
2023-07-09 08:55:56 +05:30
1. In the **Explorer** file tree, navigate to the directory where you want to upload the file.
1. Optional. If the directory does not exist yet, select the directory path where you want to have a new directory and either:
- Right-click on the directory path, and select **New Folder...**. You can create a nested directory path with the `/` separator, for example `parentdir/subdir1/subdir2`.
- In the **Explorer** panel, in the upper-right corner, select the new folder (**{folder-new}**) icon.
1. Enter the name of the new directory, and press <kbd>Enter/Return</kbd> to create it.
1. Right-click on the directory path and select `Upload...`.
1. Select the file you want to upload, then select `Open`. You can select and add multiple files at once.
2018-05-09 12:01:36 +05:30
2023-07-09 08:55:56 +05:30
The file is uploaded and automatically added as a new file to the Git repository.
2018-05-09 12:01:36 +05:30
2023-07-09 08:55:56 +05:30
## Switch branches
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
The Web IDE uses the currently selected branch by default.
To switch branches in the Web IDE:
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
1. On the status bar, in the lower-left corner, select the current branch name.
1. In the search box, start typing the branch name.
1. From the dropdown list, select the branch.
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
## Create a branch
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
To create a branch from the current branch in the Web IDE:
2018-11-08 19:23:39 +05:30
2023-07-09 08:55:56 +05:30
1. On the status bar, in the lower-left corner, select the current branch name.
1. From the dropdown list, select **Create new branch...**.
1. Enter the branch name.
1. Press <kbd>Enter</kbd>.
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
If you don't have write access to the repository, **Create new branch...** is not visible.
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
## Commit changes
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
To commit changes in the Web IDE:
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
1. On the activity bar on the left, select **Source Control**,
or press <kbd>Control</kbd>+<kbd>Shift</kbd>+<kbd>G</kbd>.
1. Enter your commit message.
1. Select **Commit & Push**.
1. Commit to the current branch, or create a new branch.
2021-10-27 15:23:28 +05:30
2023-07-09 08:55:56 +05:30
## Use the command palette
2020-06-23 00:09:42 +05:30
2023-07-09 08:55:56 +05:30
In the Web IDE, you can access many commands through the command palette.
To open the command palette and run a command in the Web IDE:
2021-10-27 15:23:28 +05:30
2023-07-09 08:55:56 +05:30
1. Press <kbd>Shift</kbd>+<kbd>Command</kbd>+<kbd>P</kbd>.
1. In the search box, start typing the command name.
1. From the dropdown list, select the command.
2021-10-27 15:23:28 +05:30
2023-07-09 08:55:56 +05:30
## Edit settings
2023-04-23 21:23:45 +05:30
2023-07-09 08:55:56 +05:30
You can use the settings editor to view and modify your user and workspace settings.
To open the settings editor in the Web IDE:
2023-04-23 21:23:45 +05:30
2023-07-09 08:55:56 +05:30
- On the top menu bar, select **File > Preferences > Settings**,
or press <kbd>Command</kbd>+<kbd>,</kbd>.
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
In the settings editor, you can search for the settings you want to modify.
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
## Edit keyboard shortcuts
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
You can use the keyboard shortcuts editor to view and modify the default keybindings for all available commands.
To open the keyboard shortcuts editor in the Web IDE:
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
- On the top menu bar, select **File > Preferences > Keyboard Shortcuts**,
or press <kbd>Command</kbd>+<kbd>K</kbd> then <kbd>Command</kbd>+<kbd>S</kbd>.
2018-11-20 20:47:30 +05:30
2023-07-09 08:55:56 +05:30
In the keyboard shortcuts editor, you can search for:
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
- The keybindings you want to change
- The commands you want to add or remove keybindings for
2021-01-29 00:20:46 +05:30
2023-07-09 08:55:56 +05:30
Keybindings are based on your keyboard layout. If you change your keyboard layout, existing keybindings are updated automatically.
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
## Change themes
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
You can choose between different themes for the Web IDE. The default theme for the Web IDE is **GitLab Dark**.
2021-09-04 01:27:46 +05:30
2023-07-09 08:55:56 +05:30
To change the Web IDE theme:
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
1. On the top menu bar, select **File > Preferences > Theme > Color Theme**,
or press <kbd>Command</kbd>+<kbd>K</kbd> then <kbd>Command</kbd>+<kbd>T</kbd>.
1. From the dropdown list, preview the themes with the arrow keys.
1. Select a theme.
2018-11-18 11:00:15 +05:30
2023-07-09 08:55:56 +05:30
The active color theme is stored in the [user settings](#edit-settings).
2023-04-23 21:23:45 +05:30
2023-07-09 08:55:56 +05:30
<!-- ## Privacy and data collection for extensions
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
The Web IDE Extension Marketplace is based on Open VSX. Open VSX does not collect any
data about you or your activities on the platform.
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
However, the privacy and data collection practices of extensions available on Open VSX can vary.
Some extensions might collect data to provide personalized recommendations or to improve the functionality.
Other extensions might collect data for analytics or advertising purposes.
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
To protect your privacy and data:
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
- Carefully review the permissions requested by an extension before you install the extension.
- Keep your extensions up to date to ensure that any security or privacy vulnerabilities are addressed promptly. -->
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
## Interactive web terminals for the Web IDE (Beta)
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
When you set up a remote development server in the Web IDE, you can use interactive web terminals to:
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
- Access a remote shell on the server.
- Interact with the server's file system and execute commands remotely.
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
You cannot use interactive web terminals to interact with a runner.
However, you can use a terminal to install dependencies and compile and debug code.
2019-07-31 22:56:46 +05:30
2023-07-09 08:55:56 +05:30
For more information about configuring a workspace that supports interactive web terminals, see [remote development](../remote_development/index.md).