Home
Microsoft

 

Azure Cloud Shell is a great tool to manage your Azure resources directly within the Azure Portal, Microsoft Docs, the Azure Mobile App or shell.azure.com. With Azure Files you even get persistent storage, which you can use to store scripts, Azure Resource Manager (ARM) templates, files and other tools. Sometimes you want to make a quick change to one of the files you are using in the Azure Cloud Shell, for that the Azure Cloud Shell comes with text editors like vi, vim, nano, and emacs. However, my favorite editor in Cloud Shell is code. Code is an editor based on the Visual Studio Code open-source project Monaco. Monaco is the same web-standards based editor that powers Visual Studio Code, and the editor is now integrated directly into Cloud Shell.

 

Cloud-Shell-Editor.gif

 

To open files in code simple write:

 

code <filename>

For example:

 

code azureresourcemanager.json

You can also just open code in a specific folder:

 

code .

To save the file, you can simply click on the top right to save file or press CTRL + S. To close the editor you can again use the menu on the top right or press CTRL + Q.

 

I hope you this gives you a quick look at how you can edit files in Azure Cloud Shell. If you have any questions, let me know in the comments.