### Configure development environment Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/devpack-for-spring Installs specific software items like OpenJDK 21 non-interactively using the setup command. ```bash devpack-for-spring setup --add openjdk-21-jdk ``` -------------------------------- ### Install dependencies Source: https://ubuntu.com/developers/docs/tutorials/python-use Install the packages listed in requirements.txt. ```bash pip install -r requirements.txt ``` -------------------------------- ### Install .NET SDK Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET SDK for development purposes. ```bash sudo apt update && sudo apt install dotnet-sdk-7.0 ``` ```bash sudo apt update && sudo apt install dotnet-sdk-6.0 ``` -------------------------------- ### Install the dotnet snap Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET snap package on the system. ```text sudo snap install --classic dotnet ``` -------------------------------- ### Install software-properties-common Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the package required to use the add-apt-repository command. ```text sudo apt update && sudo apt install software-properties-common ``` -------------------------------- ### Install NetCoreDbg Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Installs the NetCoreDbg debugger via snap. ```bash sudo snap install --classic netcoredbg ``` -------------------------------- ### Install .NET 7 SDK Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET SDK for application development. ```text sudo apt update && sudo apt install dotnet-sdk-7.0 ``` -------------------------------- ### Install make utility Source: https://ubuntu.com/developers/docs/tutorials/go-use Installs the make build automation tool on Ubuntu systems. ```bash sudo apt install make -y ``` -------------------------------- ### GDB debugging session example Source: https://ubuntu.com/developers/docs/tutorials/gcc-use A sample session demonstrating starting the program, printing variable values, and stepping through execution. ```text Reading symbols from hello... (gdb) start Temporary breakpoint 1 at 0x1155: file hello.c, line 4. Starting program: /home/rkratky/c-projects/hello-world/hello [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". ./hello Temporary breakpoint 1, main () at hello.c:4 4 int number = 42; (gdb) print number $1 = 32767 (gdb) next 5 printf("Hello, world!\nThe answer to everything is %d.\n", number); (gdb) print number $2 = 42 (gdb) ``` -------------------------------- ### Install WebStorm Source: https://ubuntu.com/developers/docs/reference/ides Commands to install PHPStorm or WebStorm via snap. ```text sudo snap install phpstorm --classic ``` ```text sudo snap install webstorm --classic ``` -------------------------------- ### Install GoLand Source: https://ubuntu.com/developers/docs/reference/ides Installs the GoLand IDE snap package. ```text sudo snap install goland --classic ``` -------------------------------- ### Install IDEs via snap Source: https://ubuntu.com/developers/docs/howto/go-setup Install Visual Studio Code or GoLand using the snap package manager. ```bash sudo snap install code --classic ``` ```bash sudo snap install goland --classic ``` -------------------------------- ### Install QEMU user-mode emulation Source: https://ubuntu.com/developers/docs/tutorials/zig-use Install the package required to run foreign-architecture binaries on Ubuntu. ```bash sudo apt install qemu-user-binfmt ``` -------------------------------- ### Install Gradle via snap Source: https://ubuntu.com/developers/docs/tutorials/java-use Use the snap package manager to install Gradle on Ubuntu. ```bash sudo snap install gradle --classic ``` -------------------------------- ### Install Go tools via go install Source: https://ubuntu.com/developers/docs/howto/go-setup Use the go tool to install the latest versions of tools when package manager versions are outdated. ```bash go install url/of/tool/@latest ``` -------------------------------- ### View installed Python packages Source: https://ubuntu.com/developers/docs/tutorials/python-use Example output from the pip list command showing installed dependencies. ```text Package Version -------- ------- certifi 2025.1.31 charset-normalizer 3.4.1 idna 3.10 pip 24.2 requests 2.32.3 urllib3 2.4.0 ``` -------------------------------- ### Install Go via Snap Source: https://ubuntu.com/developers/docs/howto/go-setup Install Go using the snap package manager, which supports specific channels for version control. ```bash sudo snap install go --classic ``` ```bash go version ``` ```bash sudo snap install go --channel=1.22/stable --classic ``` -------------------------------- ### Install WebStorm Source: https://ubuntu.com/developers/docs/reference/ides Installs the WebStorm IDE snap package. ```text sudo snap install webstorm --classic ``` -------------------------------- ### Install Android Studio Source: https://ubuntu.com/developers/docs/reference/ides Installs the Android Studio IDE snap package. ```text sudo snap install android-studio --classic ``` -------------------------------- ### Install IDEs and LSP server Source: https://ubuntu.com/developers/docs/howto/clang-setup Commands to install common C/C++ IDEs or the clangd LSP server. ```bash sudo snap install code --classic ``` ```bash sudo snap install clion --classic ``` ```bash sudo apt install qt-creator ``` ```bash sudo apt install clangd ``` -------------------------------- ### Install RustRover Source: https://ubuntu.com/developers/docs/reference/ides Installs the RustRover IDE snap package. ```text sudo snap install rustrover --classic ``` -------------------------------- ### Build a live preview Source: https://ubuntu.com/developers/docs/howto/contribute-docs Start a live preview server using the make tool, which automatically refreshes when files are saved. ```bash make run ``` -------------------------------- ### Check .NET installation information Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Displays detailed information about the installed .NET SDKs, runtimes, and environment configuration. ```text dotnet --info ``` -------------------------------- ### Install .NET SDK 8.0 Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET SDK along with suggested debug symbols. ```text sudo apt update && sudo apt install --install-suggests dotnet-sdk-8.0 ``` -------------------------------- ### Install .NET 6 Runtimes Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the ASP.NET Core runtime or the standard .NET runtime. ```text sudo apt update && sudo apt install aspnetcore-runtime-6.0 ``` ```text sudo apt update && sudo apt install dotnet-runtime-6.0 ``` -------------------------------- ### Install .NET 6 SDK Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET 6 SDK for application development. ```text sudo apt update && sudo apt install dotnet-sdk-6.0 ``` -------------------------------- ### Install CLion Source: https://ubuntu.com/developers/docs/reference/ides Installs the CLion C/C++ IDE snap package. ```text sudo snap install clion --classic ``` -------------------------------- ### Install devpack-for-spring Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/devpack-for-spring Installs the devpack-for-spring snap package using classic confinement. ```bash sudo snap install devpack-for-spring --classic --channel latest/edge ``` -------------------------------- ### Install Go via pre-compiled binaries Source: https://ubuntu.com/developers/docs/howto/go-setup Download and extract official Go binaries manually to a local directory. ```bash wget https://go.dev/dl/go.linux-amd64.tar.gz ``` ```bash sudo tar -C /usr/local -xzf go.linux-amd64.tar.gz ``` ```bash export PATH=$PATH:/usr/local/go/bin ``` -------------------------------- ### Install PyCharm Source: https://ubuntu.com/developers/docs/reference/ides Commands to install various PyCharm editions. ```text sudo snap install pycharm --candidate --classic ``` ```text sudo snap install pycharm-professional --classic ``` ```text sudo snap install pycharm-community --classic ``` -------------------------------- ### Install Maven on Ubuntu Source: https://ubuntu.com/developers/docs/tutorials/java-use Use the apt package manager to install Maven from the Ubuntu archive. ```bash sudo apt install maven ``` -------------------------------- ### Install Codium via Snap Source: https://ubuntu.com/developers/docs/howto/zig-setup Install the VSCodium editor using the classic snap package. ```bash sudo snap install codium --classic ``` -------------------------------- ### Install .NET 7 Runtimes Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Provides commands to install either the full ASP.NET Core runtime or the base .NET runtime. ```text sudo apt update && sudo apt install aspnetcore-runtime-7.0 ``` ```text sudo apt update && sudo apt install dotnet-runtime-7.0 ``` -------------------------------- ### Install Eclipse IDE Source: https://ubuntu.com/developers/docs/howto/java-setup Installs the Eclipse IDE using the snap package manager with classic confinement. ```bash snap install eclipse --classic ``` -------------------------------- ### Install IntelliJ IDEA Source: https://ubuntu.com/developers/docs/reference/ides Commands to install the Ultimate or Community editions of IntelliJ IDEA. ```text sudo snap install intellij-idea-ultimate --classic ``` ```text sudo snap install intellij-idea-community --classic ``` -------------------------------- ### Install .NET components Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs specific .NET components and versions using the dotnet-installer tool. ```text dotnet-installer install [ []] ``` ```text dotnet-installer install runtime latest ``` ```text dotnet-installer install sdk lts ``` ```text dotnet-installer install aspnetcore-runtime 8 ``` ```text dotnet-installer install sdk 9.0 ``` -------------------------------- ### Install GCC and G++ compilers Source: https://ubuntu.com/developers/docs/howto/gcc-setup Use the apt package manager to install the standard C and C++ compilers. ```bash sudo apt install gcc g++ ``` -------------------------------- ### Install Rider Source: https://ubuntu.com/developers/docs/reference/ides Installs the Rider .NET IDE snap package. ```text sudo snap install rider --classic ``` -------------------------------- ### Install RubyMine Source: https://ubuntu.com/developers/docs/reference/ides Installs the RubyMine IDE snap package. ```text sudo snap install rubymine --classic ``` -------------------------------- ### Install gopls language server Source: https://ubuntu.com/developers/docs/howto/go-setup Install the gopls language server from the Ubuntu archive. ```bash sudo apt install gopls ``` -------------------------------- ### Install Git on Ubuntu Source: https://ubuntu.com/developers/docs/explanation/use-vcs Commands to install Git using either the standard DEB package or the snap package. ```bash sudo apt install -y git ``` ```bash sudo snap install git-scm ``` -------------------------------- ### Install Java IDEs Source: https://ubuntu.com/developers/docs/howto/java-setup Installs various IDEs for Java development using snap packages. ```bash sudo snap install eclipse --classic ``` ```bash sudo snap install intellij-idea-community --classic ``` ```bash sudo snap install code --classic ``` ```bash sudo snap install android-studio --classic ``` -------------------------------- ### Install .NET 9 Runtimes Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs either the full ASP.NET Core runtime or the base .NET runtime for version 9. ```bash sudo apt update && sudo apt install --install-suggests aspnetcore-runtime-9.0 ``` ```bash sudo apt update && sudo apt install --install-suggests dotnet-runtime-9.0 ``` -------------------------------- ### Manage multiple Go versions Source: https://ubuntu.com/developers/docs/howto/go-setup Install and execute multiple versions of Go side-by-side using full paths. ```bash sudo apt install golang-1.21 golang-1.23 ``` ```bash /usr/lib/go-1.21/bin/go version > /usr/lib/go-1.23/bin/go version ``` -------------------------------- ### Verify Zig installation Source: https://ubuntu.com/developers/docs/howto/zig-setup Check the installed version of the Zig compiler. ```bash zig version ``` -------------------------------- ### Install IDEs via Snap Source: https://ubuntu.com/developers/docs/reference/ides Standard commands to install various IDEs using the snap package manager with the --classic confinement flag. ```text sudo snap install android-studio --classic ``` ```text sudo snap install clion --classic ``` ```text sudo snap install datagrip --classic ``` ```text sudo snap install eclipse --classic ``` ```text sudo snap install goland --classic ``` ```text sudo snap install intellij-idea-ultimate --classic ``` ```text sudo snap install intellij-idea-community --classic ``` ```text sudo snap install phpstorm --classic ``` ```text sudo snap install pycharm --candidate --classic ``` ```text sudo snap install pycharm-professional --classic ``` -------------------------------- ### Install .NET 8 Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the base .NET runtime without ASP.NET Core components. ```text sudo apt update && sudo apt install --install-suggests dotnet-runtime-8.0 ``` -------------------------------- ### List installed .NET SDKs Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Lists all .NET SDK versions currently installed on the system. ```text dotnet --list-sdks ``` -------------------------------- ### Install Zig via Snap Source: https://ubuntu.com/developers/docs/howto/zig-setup Install the community-maintained Zig snap package using the latest/beta channel. ```bash sudo snap install zig --classic --channel=latest/beta ``` -------------------------------- ### Install a specific Python version Source: https://ubuntu.com/developers/docs/tutorials/python-use Downloads and installs a specific Python version. ```bash pyenv install 3.12.9 ``` ```text Downloading Python-3.12.9.tar.xz... -> https://www.python.org/ftp/python/3.12.9/Python-3.12.9.tar.xz Installing Python-3.12.9... Installed Python-3.12.9 to /home/ubuntu/.pyenv/versions/3.12.9 ``` -------------------------------- ### Install PyCharm Community Source: https://ubuntu.com/developers/docs/reference/ides Installs the PyCharm Community Edition snap package. ```text sudo snap install pycharm-community --classic ``` -------------------------------- ### Install pytest dependencies Source: https://ubuntu.com/developers/docs/tutorials/python-use Command to install the necessary testing packages on Ubuntu. ```bash sudo apt install python3-pytest python3-pytest-mock ``` -------------------------------- ### Install tox on Ubuntu Source: https://ubuntu.com/developers/docs/howto/python-setup Use the apt package manager to install the tox automation tool. ```bash sudo apt install tox ``` -------------------------------- ### Install pyenv Source: https://ubuntu.com/developers/docs/howto/python-setup Install the pyenv package along with necessary build dependencies. ```bash $ sudo apt install pyenv ``` -------------------------------- ### List installed .NET runtimes Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Lists all .NET runtime versions currently installed on the system. ```text dotnet --list-runtimes ``` -------------------------------- ### List .NET components Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Displays installed and available .NET components and their versions. ```text dotnet-installer list ``` -------------------------------- ### Install .NET Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET runtime for executing applications. ASP.NET Core runtime includes additional components. ```bash sudo apt update && sudo apt install aspnetcore-runtime-7.0 ``` ```bash sudo apt update && sudo apt install dotnet-runtime-7.0 ``` ```bash sudo apt update && sudo apt install aspnetcore-runtime-6.0 ``` ```bash sudo apt update && sudo apt install dotnet-runtime-6.0 ``` -------------------------------- ### Install software from a PPA Source: https://ubuntu.com/developers/docs/explanation/packaging Commands to add a Personal Package Archive (PPA) to the system, update the package list, and install the software. ```default sudo add-apt-repository ppa:/ sudo apt update sudo apt install ``` -------------------------------- ### Install pytest on Ubuntu Source: https://ubuntu.com/developers/docs/howto/python-setup Use the apt package manager to install the pytest testing framework. ```bash sudo apt install python3-pytest ``` -------------------------------- ### Install .NET 8 ASP.NET Core Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the ASP.NET Core runtime and suggested debugging symbols. ```text sudo apt update && sudo apt install --install-suggests aspnetcore-runtime-8.0 ``` -------------------------------- ### Install .NET 10 Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the base .NET 10 runtime without ASP.NET Core components. ```text sudo apt update && sudo apt install --install-suggests dotnet-runtime-10.0 ``` -------------------------------- ### Install .NET 9 Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the base .NET 9 runtime without ASP.NET Core components. ```text sudo apt update && sudo apt install --install-suggests dotnet-runtime-9.0 ``` -------------------------------- ### Install .NET 9 SDK Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET 9 SDK along with suggested debug symbols and AOT components. ```text sudo apt update && sudo apt install --install-suggests dotnet-sdk-9.0 ``` -------------------------------- ### Install .NET Runtimes Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs specific .NET runtime packages with suggested debug symbols. ```text sudo apt update && sudo apt install --install-suggests aspnetcore-runtime-8.0 ``` ```text sudo apt update && sudo apt install --install-suggests dotnet-runtime-8.0 ``` -------------------------------- ### Install .NET with Debug Symbols Automatically Source: https://ubuntu.com/developers/docs/explanation/debugging-with-dotnet Include the --install-suggests flag during installation to automatically pull in relevant debug symbol packages. ```bash sudo apt install dotnet9 --install-suggests ``` -------------------------------- ### Initialize a Go project Source: https://ubuntu.com/developers/docs/tutorials/go-use Commands to create a project directory and initialize it as a Go module. ```bash mkdir heygo && cd heygo ``` ```bash go mod init youruser.github.com/heygo ``` -------------------------------- ### Install .NET 10 SDK Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the .NET 10 SDK along with suggested debug symbols and AOT components. ```text sudo apt update && sudo apt install --install-suggests dotnet-sdk-10.0 ``` -------------------------------- ### Create a project directory Source: https://ubuntu.com/developers/docs/tutorials/python-use Sets up a new directory for testing Python version switching. ```bash $ mkdir -p ~/my-python-project && $ cd ~/my-python-project ``` -------------------------------- ### Generate a Maven project Source: https://ubuntu.com/developers/docs/tutorials/java-use Create a new Java project structure using the Maven Quickstart archetype. ```bash mvn archetype:generate -DgroupId=com.yourcompany \ -DartifactId=helloworld -Dversion=1.0-SNAPSHOT \ -Dpackage=com.yourcompany.helloworld \ -DarchetypeGroupId=org.apache.maven.archetypes \ -DarchetypeArtifactId=maven-archetype-quickstart \ -DarchetypeVersion=1.4 ``` -------------------------------- ### Install VS Code via Snap Source: https://ubuntu.com/developers/docs/howto/zig-setup Install the Visual Studio Code editor using the classic snap package. ```bash sudo snap install code --classic ``` -------------------------------- ### Install default Java Development Kit Source: https://ubuntu.com/developers/docs/howto/java-setup Installs the default JDK package available for the current Ubuntu release. ```bash sudo apt install default-jdk ``` -------------------------------- ### Install Delve debugger Source: https://ubuntu.com/developers/docs/howto/go-setup Install the Delve debugger using the apt package manager. ```bash sudo apt install delve ``` -------------------------------- ### Initialize a new Java project with Gradle Source: https://ubuntu.com/developers/docs/tutorials/java-use Create a directory and run the gradle init command to scaffold a new Java application project. ```bash mkdir helloworld && cd helloworld gradle init \ --type java-application \ --dsl kotlin \ --test-framework junit-jupiter \ --package com.yourcompany.helloworld \ --project-name helloworld \ --no-split-project \ --no-incubating ``` -------------------------------- ### Verify GCC installation Source: https://ubuntu.com/developers/docs/howto/gcc-setup Check the installed version of the GCC compiler to ensure it is correctly configured. ```bash gcc --version ``` ```text gcc (Ubuntu 14.2.0-4ubuntu2) 14.2.0 Copyright (C) 2024 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ``` -------------------------------- ### Install default Clang Source: https://ubuntu.com/developers/docs/howto/clang-setup Installs the default Clang compiler and associated executables for the current Ubuntu release. ```bash sudo apt install clang ``` -------------------------------- ### Install Rust via Rustup Source: https://ubuntu.com/developers/docs/howto/rust-setup Installs the Rustup manager and specific toolchain versions using the snap package manager. ```bash snap install --classic rustup ``` ```bash rustup install stable ``` ```bash rustup install nightly ``` -------------------------------- ### Install Zig via APT Source: https://ubuntu.com/developers/docs/howto/zig-setup Use the system package manager to install Zig on Ubuntu 25.10 and later. ```bash sudo apt install zig ``` -------------------------------- ### Java Hello World application Source: https://ubuntu.com/developers/docs/tutorials/java-use The default App class generated by the Maven quickstart archetype. ```java package com.yourcompany.helloworld; /** * Hello world! * */ public class App { public static void main( String[] args ) { System.out.println( "Hello World!" ); } } ``` -------------------------------- ### Create a project directory Source: https://ubuntu.com/developers/docs/tutorials/gcc-use Initializes a new directory for C projects and navigates into it. ```bash mkdir -p ~/c-projects/hello-world && cd ~/c-projects/hello-world ``` -------------------------------- ### Initialize VS Code configuration files Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Creates the .vscode directory and the launch.json configuration file. ```bash mkdir .vscode && touch .vscode/launch.json ``` -------------------------------- ### Install Go via Debian package Source: https://ubuntu.com/developers/docs/howto/go-setup Use the apt package manager to install the latest Go version or a specific version. ```bash sudo apt update ``` ```bash sudo apt install golang-go ``` ```bash go version ``` ```bash sudo apt install golang- ``` -------------------------------- ### Install Rust via Ubuntu packages Source: https://ubuntu.com/developers/docs/howto/rust-setup Installs the cargo package and the rustc compiler from the official Ubuntu repositories. ```bash sudo apt install cargo ``` -------------------------------- ### Install .NET 10 ASP.NET Core Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the ASP.NET Core runtime for .NET 10, including suggested debug symbols. ```text sudo apt update && sudo apt install --install-suggests aspnetcore-runtime-10.0 ``` -------------------------------- ### Install Python package manager Source: https://ubuntu.com/developers/docs/howto/python-setup Install pip for managing dependencies within Python virtual environments. ```bash sudo apt install -y python3-pip python3-pip-whl ``` -------------------------------- ### Install .NET 9 ASP.NET Core Runtime Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Installs the ASP.NET Core runtime for .NET 9, including suggested debug symbols. ```text sudo apt update && sudo apt install --install-suggests aspnetcore-runtime-9.0 ``` -------------------------------- ### List .NET Runtimes Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Displays the currently installed .NET runtimes on the system. ```text dotnet –list-runtimes ``` -------------------------------- ### Install Python 3 full runtime Source: https://ubuntu.com/developers/docs/howto/python-setup Installs the Python interpreter along with the complete class library, venv support, and IDLE. ```bash sudo apt install -y python3-full ``` -------------------------------- ### Manage Python dependencies with pip Source: https://ubuntu.com/developers/docs/tutorials/python-use Commands for creating a requirements file, installing dependencies, and listing installed packages. ```bash echo "requests" > requirements.txt ``` ```bash pip install -r requirements.txt ``` ```bash pip list ``` -------------------------------- ### Define and run unit tests Source: https://ubuntu.com/developers/docs/tutorials/zig-use Example of a test block using std.testing and the command to execute tests. ```zig const std = @import("std"); const testing = std.testing; pub export fn add(a: i32, b: i32) i32 { return a + b; } test "basic add functionality" { try testing.expect(add(3, 7) == 10); } ``` ```bash zig build --summary all test ``` -------------------------------- ### Example .NET info output Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Sample output generated by the dotnet --info command. ```text .NET SDK: Version: 8.0.113 Commit: 67977f6ab7 Workload version: 8.0.100-manifests.bbbf61fd Runtime Environment: OS Name: ubuntu OS Version: 24.04 OS Platform: Linux RID: ubuntu.22.04-x64 Base Path: /var/snap/dotnet/common/dotnet/sdk/8.0.113/ .NET workloads installed: Workload version: 8.0.100-manifests.bbbf61fd There are no installed workloads to display. Host: Version: 9.0.1 Architecture: x64 Commit: 1cf154a56d .NET SDKs installed: 8.0.113 [/var/snap/dotnet/common/dotnet/sdk] .NET runtimes installed: Microsoft.AspNetCore.App 8.0.13 [/var/snap/dotnet/common/dotnet/shared/Microsoft.AspNetCore.App] Microsoft.NETCore.App 8.0.13 [/var/snap/dotnet/common/dotnet/shared/Microsoft.NETCore.App] Other architectures found: None Environment variables: Not set global.json file: Not found Learn more: https://aka.ms/dotnet/info Download .NET: https://aka.ms/dotnet/download 8.0.113 [/var/snap/dotnet/common/dotnet/sdk] Microsoft.AspNetCore.App 8.0.13 [/var/snap/dotnet/common/dotnet/shared/Microsoft.AspNetCore.App] Microsoft.NETCore.App 8.0.13 [/var/snap/dotnet/common/dotnet/shared/Microsoft.NETCore.App] ``` -------------------------------- ### Install specific Clang version Source: https://ubuntu.com/developers/docs/howto/clang-setup Installs a specific version of Clang, which will be available via a versioned executable name. ```bash sudo apt install clang-20 ``` -------------------------------- ### Install .NET Debug Symbols via APT Source: https://ubuntu.com/developers/docs/explanation/debugging-with-dotnet Use this command to manually install the debugging symbol packages for the .NET SDK and runtime. ```bash sudo apt install dotnet-sdk-dbg-9.0 dotnet-runtime-dbg-9.0 aspnetcore-runtime-dbg-9.0 ``` -------------------------------- ### Install specific OpenJDK versions Source: https://ubuntu.com/developers/docs/howto/java-setup Installs specific versions of OpenJDK, including early access releases and LTS versions. ```bash sudo apt install openjdk-24-jdk ``` ```bash sudo snap install openjdk --channel=edge ``` ```bash sudo snap install openjdk --channel=stable ``` ```bash sudo apt install openjdk--jdk ``` ```bash sudo apt install openjdk-21-jdk ``` -------------------------------- ### Run and build Go programs Source: https://ubuntu.com/developers/docs/tutorials/go-use Commands to execute, compile, and verify the resulting binary. ```bash go run . ``` ```bash go build . ``` ```bash ls ``` ```text go.mod heygo heygo.go ``` ```bash ./heygo ``` ```text Hey Go! ``` -------------------------------- ### Install GraalVM Community Edition Source: https://ubuntu.com/developers/docs/howto/java-setup Installs GraalVM Community Edition via snap, with options for the latest version or specific LTS channels. ```bash sudo snap install graalvm-jdk ``` ```bash sudo snap install graalvm-jdk --channel=v21 ``` -------------------------------- ### Install C/C++ build dependencies Source: https://ubuntu.com/developers/docs/howto/rust-setup Installs the build-essential package required for compiling Rust libraries that include C or C++ code. ```bash sudo apt install build-essential ``` -------------------------------- ### List available Python versions Source: https://ubuntu.com/developers/docs/tutorials/python-use Displays all installable Python versions via pyenv. ```bash pyenv install --list ``` -------------------------------- ### Configure Go binary PATH Source: https://ubuntu.com/developers/docs/howto/go-setup Manually add the Go binary directory to the system PATH for non-package manager installations. ```bash export PATH=$PATH:/path/to/your/go/bin ``` ```bash source $HOME/.profile ``` -------------------------------- ### Start GDB debugger Source: https://ubuntu.com/developers/docs/tutorials/gcc-use Launch the GDB debugger for the specified executable. ```bash gdb hello ``` -------------------------------- ### List supported build targets Source: https://ubuntu.com/developers/docs/tutorials/go-use Displays all available operating system and architecture combinations supported by the Go toolchain. ```bash go tool dist list ``` -------------------------------- ### Configure Rust for WebAssembly cross-compilation Source: https://ubuntu.com/developers/docs/howto/rust-setup Install Clang and LLD, add the WebAssembly target, and build the project for the browser. ```bash sudo apt install clang lld ``` ```bash rustup target add wasm32-unknown-unknown ``` ```bash cargo build --target wasm32-unknown-unknown ``` -------------------------------- ### Verify active Python versions Source: https://ubuntu.com/developers/docs/tutorials/python-use Lists installed versions and indicates the currently active one. ```bash pyenv versions ``` ```text system * 3.12.9 (set by /home/ubuntu/my-python-project/.python-version) ``` -------------------------------- ### Example Python script for linting Source: https://ubuntu.com/developers/docs/tutorials/python-use A sample Python script using the requests library to demonstrate style checking. ```python import requests def hello_world(): # Use the example HTTP response service url = "https://httpbin.org/post" # Define a custom header for the POST method header = {"Message": "Hello, world!"} try: # Send the defined header to the response service response = requests.post(url, headers=header) # Basic error handling response.raise_for_status() # Parse the response response_data = response.json() # Print the message print(response_data["headers"]["Message"]) except requests.exceptions.RequestException as e: print(f"An error occurred: {e}") if __name__ == "__main__": hello_world() ``` -------------------------------- ### Prepare a Python virtual environment Source: https://ubuntu.com/developers/docs/tutorials/python-use Commands to create a project directory, initialize a virtual environment, and verify the active Python path. ```bash mkdir -p ~/python/helloworld && cd ~/python/helloworld ``` ```bash python3 -m venv .venv ``` ```bash source .venv/bin/activate ``` ```bash which python3 ``` ```text /home/dev/python/helloworld/.venv/bin/python3 ``` -------------------------------- ### Set JAVA_HOME environment variable Source: https://ubuntu.com/developers/docs/tutorials/java-use Configure the JAVA_HOME variable to point to the installed JDK path. ```bash export JAVA_HOME=/usr/lib/jvm/java-21-openjdk-amd64 ``` -------------------------------- ### Configure Rust for Windows cross-compilation Source: https://ubuntu.com/developers/docs/howto/rust-setup Install the necessary MinGW toolchain packages, add the Windows target, and build the project. ```bash sudo apt install binutils-mingw-w64 g++-mingw-w64 gcc-mingw-w64 ``` ```bash rustup target add x86_64-pc-windows-gnu ``` ```bash cargo build --target x86_64-pc-windows-gnu ``` -------------------------------- ### Register the .NET backports PPA Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Adds the PPA repository to the system to enable .NET package installation. ```text sudo add-apt-repository ppa:dotnet/backports ``` -------------------------------- ### Configure APT Pinning for Proposed Updates Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Sets APT preferences to manage package installation priority from the proposed archive. ```text sudo tee /etc/apt/preferences.d/proposed-updates >/dev/null </dev/null < usize { 42 } ``` ```c #include #include extern size_t the_answer(); int main() { printf("The answer is %lu\n", the_answer()); return 0; } ``` ```bash rustc answer.rs --emit obj --crate-type=lib -Copt-level=3 -o answer.o ``` ```bash gcc -O3 c_main.c answer.o -o main ``` ```bash ./main ``` ```text The answer is 42 ``` -------------------------------- ### Set JAVA_HOME environment variable Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/graalvm-use Point the JAVA_HOME variable to the installed GraalVM directory. ```bash export JAVA_HOME=/snap/graalvm-jdk/current/graalvm-ce/ ``` -------------------------------- ### Start Spring Boot with CRaC Checkpoint Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/crac-use Launch the application using the -XX:CRaCCheckpointTo flag to specify the directory for the snapshot image. ```bash $JAVA_HOME/bin/java -XX:CRaCCheckpointTo=$HOME/cr-image \ -jar target/spring-petclinic-3.5.0-SNAPSHOT.jar ``` -------------------------------- ### Uninstall a Python version Source: https://ubuntu.com/developers/docs/tutorials/python-use Removes a specific Python version from the pyenv installation. ```bash pyenv uninstall 3.12.9 ``` -------------------------------- ### Java unit test class Source: https://ubuntu.com/developers/docs/tutorials/java-use The default unit test class generated by the Maven quickstart archetype. ```java package com.yourcompany.helloworld; import static org.junit.Assert.assertTrue; import org.junit.Test; /** * Unit test for simple App. */ public class AppTest { /** * Rigorous Test :-) */ @Test public void shouldAnswerWithTrue() { assertTrue( true ); } } ``` -------------------------------- ### Build and file listing commands Source: https://ubuntu.com/developers/docs/tutorials/gcc-use Commands to build the project using make and verify the generated files. ```bash make ``` ```text gcc -c hello.c -o hello.o gcc -o hello hello.o ``` ```bash ls -1 ``` ```text hello hello.c hello.o Makefile ``` -------------------------------- ### Define a function and call it within a loop Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Example demonstrating the use of a custom function called within a while loop to facilitate stepping into code during debugging. ```csharp var names = new List { "Alice", "Bob", "Charlie" }; var index = 0; while (index < names.Count) { SayHello(names[index]); index++; } void SayHello(string name) { Console.WriteLine($"Hello, {name}"); } ``` -------------------------------- ### Generate SSH keys for Git authentication Source: https://ubuntu.com/developers/docs/explanation/use-vcs Commands to install the SSH client and generate an ED25519 key pair for secure Git hosting access. ```bash sudo apt install -y openssh-client ``` ```bash ssh-keygen -t ed25519 -C "user@example.com" ``` -------------------------------- ### Handle externally-managed-environment errors Source: https://ubuntu.com/developers/docs/tutorials/python-use Example of the error message displayed when attempting to use pip outside of a virtual environment on Ubuntu. ```bash $ which pip /usr/bin/pip $ pip install -r requirements.txt error: externally-managed-environment × This environment is externally managed ╰─> To install Python packages system-wide, try apt install python3-xyz, where xyz is the package you are trying to install. If you wish to install a non-Debian-packaged Python package, create a virtual environment using python3 -m venv path/to/venv. Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make sure you have python3-full installed. If you wish to install a non-Debian packaged Python application, it may be easiest to use pipx install xyz, which will manage a virtual environment for you. Make sure you have pipx installed. See /usr/share/doc/python3.12/README.venv for more information. note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages. hint: See PEP 668 for the detailed specification. ``` -------------------------------- ### CRaC Restore Log Output Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/crac-use Example log output showing the lifecycle restart of Spring-managed beans after a JVM restore. ```text 2025-09-04T06:57:58.872Z WARN 7522 --- [l-1:housekeeper] com.zaxxer.hikari.pool.HikariPool : HikariPool-1 - Thread starvation or clock leap detected (housekeeper delta=4m5s281ms870µs908ns). 2025-09-04T06:57:58.896Z INFO 7522 --- [Attach Listener] o.s.c.support.DefaultLifecycleProcessor : Restarting Spring-managed lifecycle beans after JVM restore 2025-09-04T06:57:58.961Z INFO 7522 --- [Attach Listener] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat started on port 8080 (http) with context path '/' 2025-09-04T06:57:58.975Z INFO 7522 --- [Attach Listener] o.s.c.support.DefaultLifecycleProcessor : Spring-managed lifecycle restart completed (restored JVM running for 225 ms) ``` -------------------------------- ### Create a C++ source file Source: https://ubuntu.com/developers/docs/tutorials/clang-use A simple C++ program that prints 'Hello, world!' to the console. ```cpp #include int main() { std::cout << "Hello, world!\n"; } ``` -------------------------------- ### Create a new .NET console project Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Use the dotnet new command to scaffold a console application in different languages. ```bash dotnet new console ``` ```bash dotnet new console -lang F# ``` ```bash dotnet new console -lang VB ``` -------------------------------- ### Run the project Source: https://ubuntu.com/developers/docs/tutorials/java-use Execute the project using the gradle run command. ```bash gradle run ``` -------------------------------- ### Create a Java Hello World application Source: https://ubuntu.com/developers/docs/tutorials/java-use A basic Java class structure for testing compilation and execution. ```java public class App { public String getGreeting() { return "Hello World!"; } public static void main(String[] args) { System.out.println(new App().getGreeting()); } } ``` -------------------------------- ### Create a C source file Source: https://ubuntu.com/developers/docs/tutorials/zig-use A standard C source file for testing compilation. ```c #include int main(void) { printf("Hello, world!\n"); return 0; } ``` -------------------------------- ### Navigate to the documentation directory Source: https://ubuntu.com/developers/docs/howto/contribute-docs Change the current working directory to the docs folder. ```bash cd docs ``` -------------------------------- ### Create and run a Rust project with Cargo Source: https://ubuntu.com/developers/docs/tutorials/rust-use Commands to initialize a new project, view the source code, and execute the build. ```bash cargo new hello_world ``` ```bash cd hello_world ``` ```bash cat src/main.rs ``` ```rust fn main() { println!("Hello, world!"); } ``` ```bash cargo run ``` ```text Hello, world! ``` -------------------------------- ### Build and verify Windows binary Source: https://ubuntu.com/developers/docs/tutorials/go-use Compiles the current directory and lists files to confirm the creation of the executable. ```bash go build . ls ``` -------------------------------- ### Display project structure Source: https://ubuntu.com/developers/docs/tutorials/zig-use Command to view the files generated by the Zig initialization process. ```bash tree ``` -------------------------------- ### Build and run Zig project Source: https://ubuntu.com/developers/docs/tutorials/zig-use Commands to build and execute a Zig project. ```bash zig build run ``` -------------------------------- ### Run a .NET project Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Executes the application by restoring dependencies, building, and running the project. ```bash dotnet run ``` -------------------------------- ### Build and run the application Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/devpack-for-spring Uses the Gradle wrapper to compile and execute the Spring Boot application. ```bash ./gradlew bootRun ``` -------------------------------- ### Build Application with Maven Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/crac-use Compile and package the application using the configured environment. ```bash mvn clean package ``` -------------------------------- ### Test documentation locally Source: https://ubuntu.com/developers/docs/howto/contribute-docs Run these commands from the docs/ directory to validate documentation before submission. ```bash make spelling ``` ```bash make linkcheck ``` ```bash make woke ``` ```bash make pa11y ``` -------------------------------- ### Create a Go source file Source: https://ubuntu.com/developers/docs/tutorials/go-use A simple Go program that prints a message to the console. ```go package main import "fmt" func main() { fmt.Println("Hey Go!") } ``` -------------------------------- ### Implement hello_world function Source: https://ubuntu.com/developers/docs/tutorials/python-use A sample Python function that performs an HTTP POST request and prints a header message. ```python import requests # import ipdb def hello_world(): # Use the example HTTP response service url = "https://httpbin.org/post" # Define a custom header for the POST method header = {"Message": "Hello, world!"} try: # Send the defined header to the response service response = requests.post(url, headers=header) # Basic error handling response.raise_for_status() # Parse the response response_data = response.json() # # Set a breakpoint to check response data # ipdb.set_trace() # Print the message print(response_data["headers"]["Message"]) except requests.exceptions.RequestException as e: print(f"An error occurred: {e}") if __name__ == "__main__": hello_world() ``` -------------------------------- ### Execute published .NET wrapper Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Runs the application using the platform-specific wrapper file. ```bash ./HelloWorld ``` -------------------------------- ### Run the Aarch64 executable Source: https://ubuntu.com/developers/docs/tutorials/zig-use Execute the cross-compiled ARM64 binary using QEMU emulation. ```bash ./hello-arm64 ``` -------------------------------- ### Open Project in VS Code Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Launch VS Code from the current project directory. ```bash code . ``` -------------------------------- ### Publish a .NET project Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Creates a distributable version of the application in the bin/Release/net9.0/publish/ directory. ```bash dotnet publish ``` -------------------------------- ### Initial Go code with errors Source: https://ubuntu.com/developers/docs/tutorials/go-use A sample Go file containing an undefined variable and poor formatting. ```go package main; import "fmt"; func main() { fmt.Println(greeting); } ``` -------------------------------- ### Configure Ubuntu Proposed APT Repository Source: https://ubuntu.com/developers/docs/howto/dotnet-setup Adds the proposed updates repository to the system APT configuration. ```text Types: deb URIs: http://archive.ubuntu.com/ubuntu Suites: noble noble-updates noble-backports noble-proposed Components: main restricted universe multiverse Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg ``` ```text sudo tee /etc/apt/sources.list.d/ubuntu-$(lsb_release -cs)-proposed.list >/dev/null </dev/null < The answer to everything is 42. ``` -------------------------------- ### Make and run Java script Source: https://ubuntu.com/developers/docs/tutorials/java-use Commands to set execution permissions and run the Java script file. ```bash chmod +x App ``` ```bash ./App ``` -------------------------------- ### Link to Launchpad packages Source: https://ubuntu.com/developers/docs/howto/contribute-docs Use the lpsrc role to generate shortened links to Ubuntu packages on Launchpad. ```default {lpsrc}`package` ``` -------------------------------- ### Main source file content Source: https://ubuntu.com/developers/docs/tutorials/zig-use The standard main.zig file structure for printing to console. ```zig const std = @import("std"); pub fn main() !void { std.debug.print("Hello, world!\n", .{}); } ``` -------------------------------- ### Compile native executable Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/graalvm-use Execute the build command to generate a native executable for your project. ```bash ./mvnw -Pnative native:compile ``` ```bash ./gradlew nativeCompile ``` -------------------------------- ### Build and package Maven project Source: https://ubuntu.com/developers/docs/tutorials/java-use Compile the project and run unit tests using the specified compiler release version. ```bash mvn -Dmaven.compiler.release=8 package ``` -------------------------------- ### Compile and run C code natively Source: https://ubuntu.com/developers/docs/tutorials/zig-use Use zig cc to compile a C source file and execute the resulting binary. ```bash zig cc hello.c -o hello && ./hello ``` -------------------------------- ### Verify Snapshot Files Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/crac-use List the contents of the configured checkpoint directory to confirm the creation of the .img snapshot files. ```bash ls $HOME/cr-data ``` -------------------------------- ### Update launch.json with preLaunchTask Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Adds the preLaunchTask property to the existing launch.json configuration. ```diff "cwd": "${workspaceFolder}", + "preLaunchTask": "build", "pipeTransport": { ``` -------------------------------- ### Cross-compile and run for Windows Source: https://ubuntu.com/developers/docs/tutorials/zig-use Compile for Windows and execute using Wine. ```bash zig cc hello.c -target x86_64-windows-gnu -o hello.exe sudo apt install wine wine hello.exe ``` -------------------------------- ### Running the built executable Source: https://ubuntu.com/developers/docs/tutorials/gcc-use Executing the program after a successful build with make. ```bash ./hello ``` ```text Hello, world! The answer to everything is 42. ``` -------------------------------- ### Open Project in VS Codium Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Launch the VS Codium editor from the command line targeting a specific project directory. ```bash codium HelloWorld ``` -------------------------------- ### Compile and run standalone file Source: https://ubuntu.com/developers/docs/tutorials/zig-use Commands to compile a single Zig file and execute the resulting binary. ```bash zig build-exe hello.zig ``` ```bash ./hello ``` -------------------------------- ### Execute published .NET binary Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Runs the compiled DLL directly using the .NET runtime. ```bash dotnet HelloWorld.dll ``` -------------------------------- ### Clone Spring Boot PetClinic Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/crac-use Initial step to retrieve the sample application source code. ```bash git clone https://github.com/spring-projects/spring-petclinic && \ cd spring-petclinic ``` -------------------------------- ### Create a new branch Source: https://ubuntu.com/developers/docs/howto/contribute-docs Create and switch to a new branch for your documentation changes. ```bash git checkout -b ``` -------------------------------- ### View project structure Source: https://ubuntu.com/developers/docs/tutorials/java-use Display the generated project directory structure using the tree command. ```text . └── helloworld-gradle ├── app │ ├── build.gradle.kts │ └── src │ ├── main │ │ ├── java │ │ │ └── com │ │ │ └── yourcompany │ │ │ └── helloworld │ │ │ └── App.java │ │ └── resources │ └── test │ ├── java │ │ └── com │ │ └── yourcompany │ │ └── helloworld │ │ └── AppTest.java │ └── resources ├── gradle │ ├── libs.versions.toml │ └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle.kts ``` -------------------------------- ### Configure launch.json for NetCoreDbg Source: https://ubuntu.com/developers/docs/tutorials/dotnet-use Defines the debugging configuration for the .NET application using pipeTransport. ```json { "version": "0.2.0", "configurations": [ { "name": "netcoredbg", "type": "coreclr", "request": "launch", "program": "${workspaceFolder}/bin/Debug/net10.0/HelloWorld.dll", "args": [], "cwd": "${workspaceFolder}", "pipeTransport": { "pipeCwd": "${workspaceFolder}", "pipeProgram": "sh", "pipeArgs": ["-c"], "debuggerPath": "netcoredbg", "debuggerArgs": ["--interpreter=vscode"], "quoteArgs": true }, "env": { "DOTNET_ENVIRONMENT": "Development" } } ] } ``` -------------------------------- ### Compile and execute Java application Source: https://ubuntu.com/developers/docs/tutorials/java-use Commands to compile a Java source file into a specific directory and run the resulting class. ```bash javac App.java -d out ``` ```bash cd out && java App ``` -------------------------------- ### Build and run with nightly Rust Source: https://ubuntu.com/developers/docs/tutorials/rust-use Commands to compile and execute a project using the nightly toolchain. ```bash cargo +nightly build ``` ```bash cargo +nightly run ``` -------------------------------- ### Configure native build plugins Source: https://ubuntu.com/developers/docs/tutorials/java-advanced/graalvm-use Add the required native build tool plugins to your project configuration files. ```xml org.graalvm.buildtools native-maven-plugin ``` ```groovy id 'org.graalvm.buildtools.native' version '0.10.6' ``` -------------------------------- ### Configure shell environment for pyenv Source: https://ubuntu.com/developers/docs/howto/python-setup Add configuration lines to shell files to initialize pyenv. ```bash export PYENV_ROOT="$HOME/.pyenv" [[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH" eval "$(pyenv init - bash)" ``` ```bash export PYENV_ROOT="$HOME/.pyenv" [[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH" eval "$(pyenv init -)" ```