Jump to Content
Application Development

Follow your org’s app dev best practices with Cloud Code custom samples

May 20, 2021
https://storage.googleapis.com/gweb-cloudblog-publish/images/appdev.max-2600x2600.jpg
Vic Iglesias

Senior Product Manager

As an engineering leader, it can be difficult to disseminate best practices to developers in your organization. This is critical, however, as these best practices can be used as a starting point to accelerate the time-to-market for your team’s ideas. Today, we are excited to introduce custom samples in Cloud Code, our family of IDE plugins, helping you easily distribute your best practices directly to your developers’ environments. 

Cloud Code helps developers increase their productivity by providing them with:

  • An easy way to run, debug, and update their apps locally

  • YAML authoring support

  • Explorers to navigate Kubernetes and Cloud Run apps

These helpful and intuitive Cloud Code features help improve day-to-day workflows for enterprise developers. Cloud Code is available for VS Code, JetBrains IDEs (IntelliJ, PyCharm, etc), and Cloud Shell Editor

And with new custom samples, developers can quickly access your enterprise’s best code samples via a versioned Git repository directly from their IDEs. 

For example, one team may have a set of best practices for standing up a REST API using a specific set of libraries and frameworks, complete with integrated logging and monitoring systems and optimized security settings. They’ve gotten things just right to integrate with your logging and monitoring systems and security posture. Putting that code in the custom samples repository can make it easy for all other teams to access this code, right from their IDEs, and alleviate the challenge of recreating something another team has already mastered.

Video Thumbnail

Three steps to custom samples 

Setting up a custom samples repository is a straightforward process.

1. Create a repository with a configuration file that maps out which folders within your repo contain samples, and gives them a name and description.

Loading...

2. Add the repo as a sample source within your preferred IDE and pick from one of the samples.

3. Reload your IDE and get right to coding and building from your company’s recommended starting point!

https://storage.googleapis.com/gweb-cloudblog-publish/images/golang_sample.max-1700x1700.jpg

With custom samples, your developers now have the ability to access code samples that are created and maintained by your organization, right from Cloud Code. All they need to do is configure Cloud Code within their preferred IDE to retrieve your enterprise specific starter samples from a source code repository, then they can quickly get started developing with your company's requirements configured for them.

Getting started today with custom samples

With Cloud Code custom samples, you can keep developers focused on coding knowing that your organization's requirements are top of mind. We've created a custom sample repo of our own where we’ve aggregated some of our favorite Google Cloud sample apps. It provides an example of how to configure a custom sample repo using our recommended best practices. It can also be used to integrate a new set of samples into Cloud Code for you to explore. Check out the example repo here.

Try out this feature using our Cloud Shell tutorial below, which gives you a tour of adding a custom sample repo to your IDE and then creating a new app from one of the samples.

https://storage.googleapis.com/gweb-cloudblog-publish/images/cloud_shell.max-600x600.jpg

Visit the documentation pages here:

Posted in