Visual Studio Plugin

broken image


-->

Helix Plugin for Visual Studio (P4VS) seamlessly brings developers the enterprise-class version control features they need without ever having to leave the Visual Studio IDE. Download the plugin below to get started. Feature-Rich Source Code Management. Create, edit and manage workspaces and streams directly from Visual Studio. Visual Studio Live Share lets you collaboratively edit and debug any codebase with others in real time—each person working in their own familiar, personalized environment.

Git is now the default version control experience in Visual Studio 2019. Since version 16.6, we've worked on building out the feature set and iterating on it based on your feedback. The new Git experience is turned on by default for everyone with the release of version 16.8.

Tip

Git is the most widely used modern version control system, so whether you're a professional developer or if you're learning how to code, Git can be very useful to you. If you are new to Git, the https://git-scm.com/ website is a good place to start. There, you'll find cheat sheets, a popular online book, and Git Basics videos.

How to use Git in Visual Studio

We'll walk you through how to use the new Git experience in Visual Studio 2019, but if you'd like to take a quick tour first, check out the following video:
Video length: 5.27 minutes

There are three ways to start using Git with Visual Studio to be more productive:

  • Open an existing Git repository. If your code is already on your machine, you can open it by using File > Open > Project/Solution (or Folder) and Visual Studio automatically detects if it has an initialized Git repository.
  • Create a new Git repository. If your code is not associated with Git, you can create a new Git repository.
  • Clone an existing Git repository. If the code that you would like to work on is not on your machine, you can clone any existing remote repositories.

Note

Starting also with version 16.8, Visual Studio 2019 includes a fully integrated GitHub account experience. You can now add both GitHub and GitHub Enterprise accounts to your keychain. You'll be able to add and leverage them just as you do with Microsoft accounts, which means that you'll have an easier time accessing your GitHub resources across Visual Studio. For more information, see the Work with GitHub accounts in Visual Studio page.

Create a new Git repository

If your code is not associated with Git, you can start by creating a new Git repository. To do so, select Git > Create Git Repository from the menu bar. Then, in the Create a Git repository dialog box, enter your information.

The Create a Git repository dialog box makes it easy to push your new repository to GitHub. By default, your new repository is private, which means that you are the only one who can access it. If you uncheck the box, your repository will be public, which means that anyone on GitHub can view it.

Tip

Whether your repository is public or private, it's best to have a remote backup of your code stored securely on GitHub even if you are not working with a team. This also makes your code available to you no matter what computer you're using.

You can choose to create a local-only Git repository by using the Local only option. Or, you can link your local project with an existing empty remote repository on Azure DevOps or any other Git provider by using the Existing Remote option.

Clone an existing Git repository

Visual Studio includes a straightforward clone experience. If you know the URL of the repository that you would like to clone, you can paste the URL in the Repository location section and then choose the disk location you would like Visual Studio to clone to.

If you don't know the repository URL, Visual Studio makes it easy to browse to and then clone your existing GitHub or Azure DevOps repository.

Open an existing local repository

After you've cloned a repository or created one, Visual Studio detects the Git repository and adds it to your list of Local Repositories in the Git menu. From here, you can quickly access and switch between your Git repositories.

View files in Solution Explorer

When you clone a repository or open a local repository, Visual Studio switches you into that Git context by saving and closing any previously open solutions and projects. Solution Explorer loads the folder at the root of the Git repository and scans the directory tree for any View files. These include files such as CMakeLists.txt or those with the .sln file extension.

Visual Studio adjusts its View based on which View file you load in Solution Explorer:

  • If you clone a repository that contains a single .sln file, then Solution Explorer directly loads that solution for you.
  • If Solution Explorer doesn't detect any .sln files in your repository, then by default it loads Folder View.
  • If your repository has more than one .sln file, then Solution Explorer shows you the list of available Views for you to choose from.

You can toggle between the currently open View and the list of Views by using the Switch Views button in the Solution Explorer toolbar.

Git Changes window

Git tracks file changes in your repo as you work, and separates the files in your repo into three categories. These changes are equivalent to what you would see when you enter the git status command in the command line:

  • Unmodified files: These files haven't changed since your last commit.
  • Modified files: These files have changes since your last commit, but you haven't yet staged them for the next commit.
  • Staged files: These files have changes that will be added to the next commit.

As you do your work, Visual Studio keeps track of the file changes to your project in the Changes section of the Git Changes window.

When you are ready to stage changes, click the + (plus) button on each file you want to stage, or right-click a file and then select Stage. You can also stage all your modified files with one click by using the stage all + (plus) button at the top of the Changes section.

When you stage a change, Visual Studio creates a Staged Changes section. Only changes in the Staged Changes section are added to the next commit, which you can do by selecting Commit Staged. The equivalent command for this action is git commit -m 'Your commit message'. Changes can also be unstaged by clicking the (minus) button. The equivalent command for this action is git reset to unstage a single file or git reset to unstage all the files in a directory.

You can also choose not to stage your modified files by skipping the staging area. In this case, Visual Studio allows you to commit your changes directly without having to stage them. Just enter your commit message and then select Commit All. The equivalent command for this action is git commit -a.

Visual Studio also makes it easy to commit and sync with one click by using the Commit All and Push and Commit All and Sync shortcuts. When you double-click any file in the Changes and the Staged changes sections, you can see a line-by-line comparison with the unmodified version of the file.

Tip

You can associate an Azure DevOps work item with a commit by using the '#' character if you are connected to the Azure DevOps repository. You can connect your Azure DevOps repository through Team Explorer > Manage Connections.

Select an existing branch

Visual Studio displays the current branch in the selector at the top of the Git Changes window.

The current branch is also available in the status bar on the bottom-right corner of the Visual Studio IDE.

From both locations, you can switch between existing branches.

Create a new branch

You can also create a new branch. The equivalent command for this action is git checkout -b .

Creating a new branch is as simple as entering the branch name and basing it off an existing branch.

You can choose an existing local or remote branch as the base. The Checkout branch checkbox automatically switches you to the newly created branch. The equivalent command for this action is git checkout -b .

Git Repository window

Visual Studio has a new Git Repository window, which is a consolidated view of all the details in your repository, including all of the branches, remotes, and commit histories. You can access this window directly from either Git or View on the menu bar or from the status bar.

Manage branches

When you select Manage Branches from the Git menu, you'll see the branches tree-view in the Git Repository window. From the left pane, you can use the right-click context menu to checkout branches, create new branches, merge, rebase, cherry-pick, and more. When you click the branch, you can see a preview of its commit history in the right pane.

When it was first published in 1998, At Home in the World set off a furor in the literary world and beyond. Joyce Maynard's memoir broke a silence concerning her relationship—at age eighteen—with J.D. Salinger, the famously reclusive author of The Catcher in the Rye, then age fifty-three, who had read a story she wrote for The New York Times in her freshman year of college and sent her a letter that changed her. At home in the world joyce maynard. When it was first published in 1998, At Home in the World set off a furor in the literary world and beyond. Joyce Maynard's memoir broke a silence concerning her relationship―at age eighteen―with J.D. Salinger, the famously reclusive author of The Catcher in the Rye, then age fifty-three, who had read a story she wrote for The New York Times in her freshman year of college and sent her a letter that. AT HOME IN THE WORLD is the mesmerizing memoir by Joyce Maynard that chronicles her devastating, all-consuming relationship with renowned novelist, J. On the surface, it seems inexplicable: why would an eighteen-year-old girl 'fall in love' with a fifty-three year-old man? But now, having read the book, I feel I understand. Joyce Maynard with Charlie Rose, talking about At Home in the World An interview with Joyce Maynard by Charlie Rose regarding her relationship at age 19 with J. At Home in the World: Excerpt from the New Preface.

Incoming and outgoing commits

When you fetch a branch, the Git Changes window has an indicator under the branch drop-down, which displays the number of unpulled commits from the remote branch. This indicator also shows you the number of unpushed local commits.

The indicator also functions as a link to take you to the commit history of that branch in the Git Repository window. The top of the history now displays the details of these incoming and outgoing commits. From here, you can also decide to Pull or Push the commits.

Commit Details

When you double-click a Commit, Visual Studio opens its details in a separate tool window. From here you can revert the commit, reset the commit, amend the commit message, or create a tag on the commit. When you click a changed file in the commit, Visual Studio opens the side-by-side Diff view of the commit and its parent.

Handle merge conflicts

Conflicts can occur during a merge if two developers modify the same lines in a file and Git doesn't automatically know which is correct. Git halts the merge and informs you that you are in a conflicted state.

Visual Studio makes it easy to identify and resolve a merge conflict. First, the Git Repository window shows a gold info bar at the top of the window.

The Git Changes window also displays a ‘Merge is in progress with conflicts' message, with the unmerged files in their separate section below it.

But if you have neither of these windows open, and instead you go to the file that has merge conflicts, you won't have to search for the following text:

Instead, Visual Studio displays a gold info bar on the top of the page that indicates that the opened file has conflicts. Then, you can click the link to open the Merge Editor.

The Merge Editor

The Merge Editor in Visual Studio is a three-way merge tool that displays the incoming changes, your current changes, and the result of the merge. You can use the tool bar at the top level of the Merge Editor to navigate between conflicts and auto-merged differences in the file.

You can also use the toggles to show/hide differences, show/hide word differences, and customize the layout. There are checkboxes on the top of each side that you can use to take all the changes from one side or the other. But to take individual changes, you can click the checkboxes to the left of the conflicting lines on either side. Finally, when you finish resolving the conflicts, you can select the Accept Merge button in the Merge Editor. You then write a commit message and commit the changes to complete the resolution.

Personalize your Git settings

To personalize and customize your Git settings at a repository level as well as at a global level, go to either Git > Settings on the menu bar, or to Tools > Options > Source Control on the menu bar. Omnifocus web release notes. Then, choose the options you want.

How to use the full Team Explorer experience in Visual Studio

The new Git experience is the default version control system in Visual Studio 2019 from version 16.8 onwards. However, if you want to turn it off, you can. Go to Tools > Options > Environment > Preview Features and then toggle the New Git user experience checkbox, which will switch you back to Team Explorer for Git.

What's next

While the new Git experience is now on by default in Visual Studio 2019 version 16.8, we continue to add new features to enhance the experience. If you'd like to check out new updates to the Git experience in a Preview release, you can download and install it from the Visual Studio Preview page.

Important

Visual Studio Plugin For Qt

If you have a suggestion for us, please let us know! We appreciate the opportunity to engage with you on design decisions via the Developer Community portal.

See also

  • Get Started with Git and GitHub in Visual Studio tutorial on Microsoft Learn
  • Getting started with Git in Visual Studio video on YouTube
  • Announcing the Release of the Git Experience in Visual Studio blog post
  • The launch of the new Git experience video on YouTube
  • The Visual Studio Toolbox series presents: The new Git experience video on Channel 9 and on YouTube
  • Exciting new updates to the Git experience in Visual Studio blog post
  • Improved Git Experience in Visual Studio 2019 blog post

Rich PlantUML support for Visual Studio Code.

Donate by Paypal|Donate by AliPay|PlantUML Document

Notice 1

Some sensitive config, like java, jar, are potentially utilized by attackers. The lastest release has disabled the workspace/work folder level settings of them by default. To enable, you have to explicitly execute the command PlantUML: Toggle Workspace Trust Flag to trust the workspace.

Thanks RyotaK for the report

Notice 2

The server render is now very recommended by this extension, since it's much faster and much easier to setup, while the major weakness has been improved:

  • Enables POST method, you can now render very-large diagrams
  • The extension comes with a new include processor, you won't encounter include problems again.

To make sure you can benifit from this update, make sure your plantuml server enables POST support.

If not, like the official https://www.plantuml.com/plantuml, the extension falls back to use GET, and you may still encounter 414 URI Too Long errors. Setup your own server is recommended.

Features

  • Preview Diagram, Press Alt-D to start PlantUML preview.
    • Auto update.
    • Zoom & scroll support.
    • Multi-Page Diagram support.
    • Instant preview, if diagram's been exported.
    • From local or server.
    • Snap to Border
  • Export Diagrams
    • At cursor, in current file, in whole workspace, in workspace selected.
    • Concurrent export.
    • Generate URLs.
    • Multi-Page Diagram support.
    • From local or server.
    • Image map (cmapx) support.
  • Editing Supports
    • Format PlantUML code. (Deprecated)
    • All type syntax highlight.
    • All type snippets.
    • Basic auto completion & macro signature support
    • Symbol List support.
  • Others
    • Multi-root Workspace Support.
    • MarkDown integrating support. View Demo
    • Extracting source from images support.

Notice: If you use customize plantuml.jar, please update to the latest version to enable Multi-Page Diagram support. (Later than V1.2017.15)

Format PlantUML code is Deprecated. Don't depend on it, use it only when it works right. I had force disable it in auto-format cases (format on save).

Supported Formats

*.wsd, *.pu, *.puml, *.plantuml, *.iuml

How to install

Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.

ext install plantuml

Requirements

Depend on which render you choose, plugin has diffrerent requirements.

Requirements for PlantUMLServer render

A plantuml server. See Use PlantUML Server as render.

Requirements for Local render

It's necessary to have following installed:

  • Java : Platform for PlantUML running.
  • Graphviz : PlantUML requires it to calculate positions in diagram.

Quick Install for Mac

Quick Install for Windows

For windows user, majkinetor introduced a way to install plantuml and its dependencies easily. Run cmd.exe as Administrator, and run two commands as follow

Plugin has integrated a copy of 'plantuml.jar', you are good to go now. But if you want to use your own jar (maybe a newer version, or with many dependent jars), specify the jar location with setting plantuml.jar.

If you've installed java, but still prompts 'java not installed', please add java bin path to PATH environment variable.

Typical Files Organization

  • Default extension settings works for independent Plantuml projects.
  • If Plantuml files are only part of your project (as documetation), use plantuml.diagramsRoot and plantuml.exportOutDir to setting up the organization, for example:

You'll get export results like:

Include Files Search Logic

Latest version has changed the include files search logic once again.It is possible to configure includepaths now in settings.json.

The new search order is as follows:

  1. The folder of the rendered file
  2. The includepaths as configured in settings.json
  1. The diagramsRoot

The setting includeSearch is not needed anymore, since the folder of the plantuml file and the diagramsRoot are always both in the include path.

To new projects, it's recommended not to rely on diagramsRoot and configure all required includepaths explicitly.

Thanks anotherandi for the brilliant idea and implementation!

Preview Demos

Preview page provides various zoom/pan actions and snap feature:

  • Zoom operations (since version 2.7.0):
    • Zoom to select area
    • Pinch to zoom (TouchPad)
    • Click to zoom in, alt + click to zoom out
    • Ctrl + mouse scroll to zoom in/out
    • Middle mouse button click to toggle zoom
    • Zoom in / zoom out / toggle buttons of the controls bar.
  • Pan operations (since version 2.7.0):
    • Right mouse button drag
    • Two-finger move to pan (TouchPad)
    • Mouse scroll
  • Snap to border (since v2.8.0):
    • Scroll to most bottom/right/top/left, preview will snap to that border.

    e.g. Snap to Bottom is useful while writing long activity diagrams, which helps you keep focus in the latest part in the bottom.

Auto update:

zoom & scroll:

Multi-Page View:

Export Demos

Export diagram:

Generate URLs

Extract Diagram Source

About Format

PlantUML formatter is disabled (since v2.8.3) if editor.formatOnSave is on.Because the formatter is not reliable enough according to user feedbacks.

About Snippets

This plugin integrates all type diagram snippets. They are splitted into 9 sections:

  • diagram: snippets for general diagrams elements.
  • activity: snippets for activity diagrams.
  • class: snippets for class diagrams.
  • component: snippets for component diagrams.
  • state: snippets for state diagrams.
  • usecase: snippets for usecase diagrams.
  • sequence: snippets for sequence diagrams.
  • ui: snippets for salt diagrams.
  • egg: snippets for some funny diagrams, like sudoku, earth.

For exsample, type acife (short version) to trigge following snippet (activity➤if・else):

Visual Studio Plugin

Tip

Git is the most widely used modern version control system, so whether you're a professional developer or if you're learning how to code, Git can be very useful to you. If you are new to Git, the https://git-scm.com/ website is a good place to start. There, you'll find cheat sheets, a popular online book, and Git Basics videos.

How to use Git in Visual Studio

We'll walk you through how to use the new Git experience in Visual Studio 2019, but if you'd like to take a quick tour first, check out the following video:
Video length: 5.27 minutes

There are three ways to start using Git with Visual Studio to be more productive:

  • Open an existing Git repository. If your code is already on your machine, you can open it by using File > Open > Project/Solution (or Folder) and Visual Studio automatically detects if it has an initialized Git repository.
  • Create a new Git repository. If your code is not associated with Git, you can create a new Git repository.
  • Clone an existing Git repository. If the code that you would like to work on is not on your machine, you can clone any existing remote repositories.

Note

Starting also with version 16.8, Visual Studio 2019 includes a fully integrated GitHub account experience. You can now add both GitHub and GitHub Enterprise accounts to your keychain. You'll be able to add and leverage them just as you do with Microsoft accounts, which means that you'll have an easier time accessing your GitHub resources across Visual Studio. For more information, see the Work with GitHub accounts in Visual Studio page.

Create a new Git repository

If your code is not associated with Git, you can start by creating a new Git repository. To do so, select Git > Create Git Repository from the menu bar. Then, in the Create a Git repository dialog box, enter your information.

The Create a Git repository dialog box makes it easy to push your new repository to GitHub. By default, your new repository is private, which means that you are the only one who can access it. If you uncheck the box, your repository will be public, which means that anyone on GitHub can view it.

Tip

Whether your repository is public or private, it's best to have a remote backup of your code stored securely on GitHub even if you are not working with a team. This also makes your code available to you no matter what computer you're using.

You can choose to create a local-only Git repository by using the Local only option. Or, you can link your local project with an existing empty remote repository on Azure DevOps or any other Git provider by using the Existing Remote option.

Clone an existing Git repository

Visual Studio includes a straightforward clone experience. If you know the URL of the repository that you would like to clone, you can paste the URL in the Repository location section and then choose the disk location you would like Visual Studio to clone to.

If you don't know the repository URL, Visual Studio makes it easy to browse to and then clone your existing GitHub or Azure DevOps repository.

Open an existing local repository

After you've cloned a repository or created one, Visual Studio detects the Git repository and adds it to your list of Local Repositories in the Git menu. From here, you can quickly access and switch between your Git repositories.

View files in Solution Explorer

When you clone a repository or open a local repository, Visual Studio switches you into that Git context by saving and closing any previously open solutions and projects. Solution Explorer loads the folder at the root of the Git repository and scans the directory tree for any View files. These include files such as CMakeLists.txt or those with the .sln file extension.

Visual Studio adjusts its View based on which View file you load in Solution Explorer:

  • If you clone a repository that contains a single .sln file, then Solution Explorer directly loads that solution for you.
  • If Solution Explorer doesn't detect any .sln files in your repository, then by default it loads Folder View.
  • If your repository has more than one .sln file, then Solution Explorer shows you the list of available Views for you to choose from.

You can toggle between the currently open View and the list of Views by using the Switch Views button in the Solution Explorer toolbar.

Git Changes window

Git tracks file changes in your repo as you work, and separates the files in your repo into three categories. These changes are equivalent to what you would see when you enter the git status command in the command line:

  • Unmodified files: These files haven't changed since your last commit.
  • Modified files: These files have changes since your last commit, but you haven't yet staged them for the next commit.
  • Staged files: These files have changes that will be added to the next commit.

As you do your work, Visual Studio keeps track of the file changes to your project in the Changes section of the Git Changes window.

When you are ready to stage changes, click the + (plus) button on each file you want to stage, or right-click a file and then select Stage. You can also stage all your modified files with one click by using the stage all + (plus) button at the top of the Changes section.

When you stage a change, Visual Studio creates a Staged Changes section. Only changes in the Staged Changes section are added to the next commit, which you can do by selecting Commit Staged. The equivalent command for this action is git commit -m 'Your commit message'. Changes can also be unstaged by clicking the (minus) button. The equivalent command for this action is git reset to unstage a single file or git reset to unstage all the files in a directory.

You can also choose not to stage your modified files by skipping the staging area. In this case, Visual Studio allows you to commit your changes directly without having to stage them. Just enter your commit message and then select Commit All. The equivalent command for this action is git commit -a.

Visual Studio also makes it easy to commit and sync with one click by using the Commit All and Push and Commit All and Sync shortcuts. When you double-click any file in the Changes and the Staged changes sections, you can see a line-by-line comparison with the unmodified version of the file.

Tip

You can associate an Azure DevOps work item with a commit by using the '#' character if you are connected to the Azure DevOps repository. You can connect your Azure DevOps repository through Team Explorer > Manage Connections.

Select an existing branch

Visual Studio displays the current branch in the selector at the top of the Git Changes window.

The current branch is also available in the status bar on the bottom-right corner of the Visual Studio IDE.

From both locations, you can switch between existing branches.

Create a new branch

You can also create a new branch. The equivalent command for this action is git checkout -b .

Creating a new branch is as simple as entering the branch name and basing it off an existing branch.

You can choose an existing local or remote branch as the base. The Checkout branch checkbox automatically switches you to the newly created branch. The equivalent command for this action is git checkout -b .

Git Repository window

Visual Studio has a new Git Repository window, which is a consolidated view of all the details in your repository, including all of the branches, remotes, and commit histories. You can access this window directly from either Git or View on the menu bar or from the status bar.

Manage branches

When you select Manage Branches from the Git menu, you'll see the branches tree-view in the Git Repository window. From the left pane, you can use the right-click context menu to checkout branches, create new branches, merge, rebase, cherry-pick, and more. When you click the branch, you can see a preview of its commit history in the right pane.

When it was first published in 1998, At Home in the World set off a furor in the literary world and beyond. Joyce Maynard's memoir broke a silence concerning her relationship—at age eighteen—with J.D. Salinger, the famously reclusive author of The Catcher in the Rye, then age fifty-three, who had read a story she wrote for The New York Times in her freshman year of college and sent her a letter that changed her. At home in the world joyce maynard. When it was first published in 1998, At Home in the World set off a furor in the literary world and beyond. Joyce Maynard's memoir broke a silence concerning her relationship―at age eighteen―with J.D. Salinger, the famously reclusive author of The Catcher in the Rye, then age fifty-three, who had read a story she wrote for The New York Times in her freshman year of college and sent her a letter that. AT HOME IN THE WORLD is the mesmerizing memoir by Joyce Maynard that chronicles her devastating, all-consuming relationship with renowned novelist, J. On the surface, it seems inexplicable: why would an eighteen-year-old girl 'fall in love' with a fifty-three year-old man? But now, having read the book, I feel I understand. Joyce Maynard with Charlie Rose, talking about At Home in the World An interview with Joyce Maynard by Charlie Rose regarding her relationship at age 19 with J. At Home in the World: Excerpt from the New Preface.

Incoming and outgoing commits

When you fetch a branch, the Git Changes window has an indicator under the branch drop-down, which displays the number of unpulled commits from the remote branch. This indicator also shows you the number of unpushed local commits.

The indicator also functions as a link to take you to the commit history of that branch in the Git Repository window. The top of the history now displays the details of these incoming and outgoing commits. From here, you can also decide to Pull or Push the commits.

Commit Details

When you double-click a Commit, Visual Studio opens its details in a separate tool window. From here you can revert the commit, reset the commit, amend the commit message, or create a tag on the commit. When you click a changed file in the commit, Visual Studio opens the side-by-side Diff view of the commit and its parent.

Handle merge conflicts

Conflicts can occur during a merge if two developers modify the same lines in a file and Git doesn't automatically know which is correct. Git halts the merge and informs you that you are in a conflicted state.

Visual Studio makes it easy to identify and resolve a merge conflict. First, the Git Repository window shows a gold info bar at the top of the window.

The Git Changes window also displays a ‘Merge is in progress with conflicts' message, with the unmerged files in their separate section below it.

But if you have neither of these windows open, and instead you go to the file that has merge conflicts, you won't have to search for the following text:

Instead, Visual Studio displays a gold info bar on the top of the page that indicates that the opened file has conflicts. Then, you can click the link to open the Merge Editor.

The Merge Editor

The Merge Editor in Visual Studio is a three-way merge tool that displays the incoming changes, your current changes, and the result of the merge. You can use the tool bar at the top level of the Merge Editor to navigate between conflicts and auto-merged differences in the file.

You can also use the toggles to show/hide differences, show/hide word differences, and customize the layout. There are checkboxes on the top of each side that you can use to take all the changes from one side or the other. But to take individual changes, you can click the checkboxes to the left of the conflicting lines on either side. Finally, when you finish resolving the conflicts, you can select the Accept Merge button in the Merge Editor. You then write a commit message and commit the changes to complete the resolution.

Personalize your Git settings

To personalize and customize your Git settings at a repository level as well as at a global level, go to either Git > Settings on the menu bar, or to Tools > Options > Source Control on the menu bar. Omnifocus web release notes. Then, choose the options you want.

How to use the full Team Explorer experience in Visual Studio

The new Git experience is the default version control system in Visual Studio 2019 from version 16.8 onwards. However, if you want to turn it off, you can. Go to Tools > Options > Environment > Preview Features and then toggle the New Git user experience checkbox, which will switch you back to Team Explorer for Git.

What's next

While the new Git experience is now on by default in Visual Studio 2019 version 16.8, we continue to add new features to enhance the experience. If you'd like to check out new updates to the Git experience in a Preview release, you can download and install it from the Visual Studio Preview page.

Important

Visual Studio Plugin For Qt

If you have a suggestion for us, please let us know! We appreciate the opportunity to engage with you on design decisions via the Developer Community portal.

See also

  • Get Started with Git and GitHub in Visual Studio tutorial on Microsoft Learn
  • Getting started with Git in Visual Studio video on YouTube
  • Announcing the Release of the Git Experience in Visual Studio blog post
  • The launch of the new Git experience video on YouTube
  • The Visual Studio Toolbox series presents: The new Git experience video on Channel 9 and on YouTube
  • Exciting new updates to the Git experience in Visual Studio blog post
  • Improved Git Experience in Visual Studio 2019 blog post

Rich PlantUML support for Visual Studio Code.

Donate by Paypal|Donate by AliPay|PlantUML Document

Notice 1

Some sensitive config, like java, jar, are potentially utilized by attackers. The lastest release has disabled the workspace/work folder level settings of them by default. To enable, you have to explicitly execute the command PlantUML: Toggle Workspace Trust Flag to trust the workspace.

Thanks RyotaK for the report

Notice 2

The server render is now very recommended by this extension, since it's much faster and much easier to setup, while the major weakness has been improved:

  • Enables POST method, you can now render very-large diagrams
  • The extension comes with a new include processor, you won't encounter include problems again.

To make sure you can benifit from this update, make sure your plantuml server enables POST support.

If not, like the official https://www.plantuml.com/plantuml, the extension falls back to use GET, and you may still encounter 414 URI Too Long errors. Setup your own server is recommended.

Features

  • Preview Diagram, Press Alt-D to start PlantUML preview.
    • Auto update.
    • Zoom & scroll support.
    • Multi-Page Diagram support.
    • Instant preview, if diagram's been exported.
    • From local or server.
    • Snap to Border
  • Export Diagrams
    • At cursor, in current file, in whole workspace, in workspace selected.
    • Concurrent export.
    • Generate URLs.
    • Multi-Page Diagram support.
    • From local or server.
    • Image map (cmapx) support.
  • Editing Supports
    • Format PlantUML code. (Deprecated)
    • All type syntax highlight.
    • All type snippets.
    • Basic auto completion & macro signature support
    • Symbol List support.
  • Others
    • Multi-root Workspace Support.
    • MarkDown integrating support. View Demo
    • Extracting source from images support.

Notice: If you use customize plantuml.jar, please update to the latest version to enable Multi-Page Diagram support. (Later than V1.2017.15)

Format PlantUML code is Deprecated. Don't depend on it, use it only when it works right. I had force disable it in auto-format cases (format on save).

Supported Formats

*.wsd, *.pu, *.puml, *.plantuml, *.iuml

How to install

Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.

ext install plantuml

Requirements

Depend on which render you choose, plugin has diffrerent requirements.

Requirements for PlantUMLServer render

A plantuml server. See Use PlantUML Server as render.

Requirements for Local render

It's necessary to have following installed:

  • Java : Platform for PlantUML running.
  • Graphviz : PlantUML requires it to calculate positions in diagram.

Quick Install for Mac

Quick Install for Windows

For windows user, majkinetor introduced a way to install plantuml and its dependencies easily. Run cmd.exe as Administrator, and run two commands as follow

Plugin has integrated a copy of 'plantuml.jar', you are good to go now. But if you want to use your own jar (maybe a newer version, or with many dependent jars), specify the jar location with setting plantuml.jar.

If you've installed java, but still prompts 'java not installed', please add java bin path to PATH environment variable.

Typical Files Organization

  • Default extension settings works for independent Plantuml projects.
  • If Plantuml files are only part of your project (as documetation), use plantuml.diagramsRoot and plantuml.exportOutDir to setting up the organization, for example:

You'll get export results like:

Include Files Search Logic

Latest version has changed the include files search logic once again.It is possible to configure includepaths now in settings.json.

The new search order is as follows:

  1. The folder of the rendered file
  2. The includepaths as configured in settings.json
  1. The diagramsRoot

The setting includeSearch is not needed anymore, since the folder of the plantuml file and the diagramsRoot are always both in the include path.

To new projects, it's recommended not to rely on diagramsRoot and configure all required includepaths explicitly.

Thanks anotherandi for the brilliant idea and implementation!

Preview Demos

Preview page provides various zoom/pan actions and snap feature:

  • Zoom operations (since version 2.7.0):
    • Zoom to select area
    • Pinch to zoom (TouchPad)
    • Click to zoom in, alt + click to zoom out
    • Ctrl + mouse scroll to zoom in/out
    • Middle mouse button click to toggle zoom
    • Zoom in / zoom out / toggle buttons of the controls bar.
  • Pan operations (since version 2.7.0):
    • Right mouse button drag
    • Two-finger move to pan (TouchPad)
    • Mouse scroll
  • Snap to border (since v2.8.0):
    • Scroll to most bottom/right/top/left, preview will snap to that border.

    e.g. Snap to Bottom is useful while writing long activity diagrams, which helps you keep focus in the latest part in the bottom.

Auto update:

zoom & scroll:

Multi-Page View:

Export Demos

Export diagram:

Generate URLs

Extract Diagram Source

About Format

PlantUML formatter is disabled (since v2.8.3) if editor.formatOnSave is on.Because the formatter is not reliable enough according to user feedbacks.

About Snippets

This plugin integrates all type diagram snippets. They are splitted into 9 sections:

  • diagram: snippets for general diagrams elements.
  • activity: snippets for activity diagrams.
  • class: snippets for class diagrams.
  • component: snippets for component diagrams.
  • state: snippets for state diagrams.
  • usecase: snippets for usecase diagrams.
  • sequence: snippets for sequence diagrams.
  • ui: snippets for salt diagrams.
  • egg: snippets for some funny diagrams, like sudoku, earth.

For exsample, type acife (short version) to trigge following snippet (activity➤if・else):

About Symbol List (List diagrams of file)

Press Ctrl+Shift+O to list all diagrams in the file. You can name the diagram when diagram starts.

@startuml diagram namesudoku@enduml

About Render

Plugin supports two renders: Local and PlantUMLServer.

Local is the default and traditional way. If you care more about export speed, you should try PlantUMLServer.

Advantages and Disadvantages of PlantUMLServer Render

Advantages:

  • 15X times faster export and much quicker preview response.
  • Don't have to set local enviroments if you have a server in your team.
  • You don't need plantuml.exportConcurrency, because it's unlimited in concurrency.

Disadvantages:

  • ~~Cannot render very-large diagrams (414 URI Too Long).~~
  • ~~Cannot render diagrams with !include in it.~~
  • Less format support: png, svg, txt.
  • Some settings are not applicable: plantuml.jar, plantuml.commandArgs, plantuml.jarArgs.

Use PlantUML Server as Render

To render very-large diagrams with include support, please make sure your plantuml server enables POST support.

If not, like the official https://www.plantuml.com/plantuml, the extension falls back to use GET, and you may still encounter 414 URI Too Long errors.

Setup your own server is recommended.

  • You may already have a PlantUML server in your team, find the server address, like: http://192.168.1.100:8080.

  • If don't have one, set up following the instructions, run with Docker is recommended. Find the server address, like: http://localhost:8080, or http://192.168.1.100:8080 which is ready for sharing to your team.

  • Open user setting, and configure like:

Multiple languages support

Translations are welcome. lang.nls.json, package.nls.json

MarkDown integrating

@startuml / @enduml is still recommended, so that PlantUML code in Markdown can be managed by other function of this plugin.

Extension Settings

This extension contributes the following settings.

Render Select:

  • plantuml.render: Select diagram render for both export and preview.

Visual Studio Code Marketplace

PlantUMLServer Render Settings:

  • plantuml.server: PlantUML server to generate UML diagrams on-the-fly.

Local Render Settings:

  • plantuml.java: Java executable location.
  • plantuml.commandArgs: commandArgs allows you add command arguments to java command, such as -DPLANTUML_LIMIT_SIZE=8192.
  • plantuml.jar: Alternate plantuml.jar location. Leave it blank to use integrated jar.
  • plantuml.jarArgs: jarArgs allows you add arguments to plantuml.jar, such as -config plantuml.config.
  • plantuml.includepaths: Specifies the include paths besides source folder and the diagramsRoot.

Export Settings:

  • plantuml.diagramsRoot: Specifies where all diagram files located (relative to workspace folder).
  • plantuml.exportOutDir: Exported workspace diagrams will be organized in this directory (relative path to workspace folder).
  • plantuml.fileExtensions: File extensions that find to export. Especially in workspace settings, you may add your own extensions so as to export diagrams in source code files, like '.java'.
  • plantuml.exportFormat: format to export. default is not set, user may pick one format everytime exports. You can still set a format for it if you don't want to pick.
  • plantuml.exportSubFolder: export diagrams to a folder which has same name with host file.
  • plantuml.exportConcurrency: decides concurrency count when export multiple diagrams.
  • plantuml.exportMapFile: Determine whether export image map (.cmapx) file when export.

Preview Settings:

  • plantuml.previewAutoUpdate: Dedecides if automatically update the preview window.

URL Generating Settings:

Visual Studio Plugin For Git

  • plantuml.urlFormat: URL format. Leave it blank to pick format everytime you generate a URL.
  • plantuml.urlResult: URL result type. Simple URL or ready for MarkDown use.

Known Issues

Please post and view issues on GitHub

Thanks

Translators

Visual Studio Code Extensions

  • Japanese: Kohei Arao, kannkyo
  • Tranditional Chinese: Alan Tsai
  • German: Fabian F.
  • French: Zepmanbc, FlorianKempenich
  • Danish: Mikkel O. Laursen

Donators

Thanks for your encouragements!

Claus Appel, 三島木​一磨, 富吉​佑季, 黒田悦成, Jared Birdsall, Suleyman Cabir Ciplak, Malcolm Learner, Сысоев Максим, Gokan Kenichi, anb0s, Lawrence Yarian, Ahmad Ragab, 山田​暁通

Enjoy!





broken image