Installing Packages

Soar provides several flexible ways to install packages. This guide covers all installation methods and options.

Basic Installation

To install a package, use either the install command or its aliases:

# Using install command
soar install <package>

# Using shorter alias
soar i <package>

# Using add alias
soar add <package>

Example: Install the soar package

soar install soar

Installing from Specific Families

Packages can be organized into families (like categories). To install a package from a specific family:

soar install <family>/<package>

Example: Install the cat package from the busybox family

soar install busybox/cat

Installing from Specific Collections

Packages can also be organized into collections. To install a package from a specific collection:

soar install <package>#<collection>

Example: Install the 7z package from the bin collection

soar install 7z#bin

Installing Multiple Packages

To install multiple packages, list them after the command:

soar install <package1> <package2> <package3>

Example: Install the bat and 7z packages

soar install bat 7z

Force Installation

To force installation even if the package already exists, use the --force flag:

soar install <package> --force

Example: Install the bat package even if it already exists

soar install bat --force

Non-Interactive Installation

By default, Soar prompts for confirmation before installing packages if multiple packages are found. To skip this prompt, use the --yes flag:

soar install <package> --yes

Example: Install the cat package without confirmation

soar install cat --yes
Note: The `--yes` flag is useful for non-interactive installations, but it's generally recommended to use it with caution. It will install the first package if multiple packages are found.