Environment Setup Shortcuts#
Setting up a development environment is often one of the first tasks when starting a new project. This typically involves installing software development kits (SDKs) and development tools, configuring environment variables, and ensuring that build tools can locate the resources they need.
Without a package manager, these tasks can become repetitive and error-prone. You may spend time manually downloading tools, updating environment variables, or troubleshooting configuration issues before you can begin writing code.
Silicon Labs Tool (SLT) simplifies this process by managing SDKs, development tools, and workspace configuration. Together, SLT and the Silicon Labs Configurator command-line interface (SLC-CLI) reduce the amount of manual setup required and provide a consistent development environment across machines.
This topic highlights shortcuts and best practices that help you set up your development environment quickly and efficiently.
Use Shell Variables to Reduce Repeated Commands#
If you are performing several operations with the same SDK or tool, store the resolved location in a shell variable.
For example:
SDK="$(slt where simplicity-sdk)" SLC="$(slt where slc-cli)"
You can then reuse these values throughout your session.
"$SLC" generate app.slcp --sdk "$SDK"
Shell variables improve readability and keep you from running the same command repeatedly.
Create Simple Shell Shortcuts#
If you frequently work with the SDK or development tools, consider creating small shell helper functions.
For example:
sdkpath() { slt where simplicity-sdk }
You can then navigate to the SDK quickly.
cd "$(sdkpath)"
You can create similar shortcuts for other commonly used tools.
These helpers reduce typing and make interactive development more convenient.