Skip to content

CLI Reference

📘 CLI ReferenceLink

Complete reference for all Sierra Dev command-line tools.

🚀 Quick ReferenceLink

Command Purpose Example
init Create new environment sierra-dev init my_project
build Compile invokers sierra-dev build
check Run validation sierra-dev check
health Environment status sierra-dev health
repo add Add package source sierra-dev repo add <url>
search Find packages sierra-dev search osint
install Install package sierra-dev install tool-name
update Update packages sierra-dev update --all
list List packages sierra-dev list --installed
remove Uninstall package sierra-dev remove tool-name

🎯 Global OptionsLink

Available for most commands:

Bash
1
2
3
-h, --help          Show help message
-v, --verbose       Enable debug logging
--env ENV_NAME      Specify environment (default: default_env)

📂 Environment CommandsLink

init - Initialize EnvironmentLink

Create a new Sierra environment for your projects.

Syntax:

Bash
sierra-dev init [name] [--force]

Arguments: - name - Environment name (default: default_env) - --force - Overwrite existing environment

Examples:

Bash
1
2
3
4
5
6
7
8
# Create default environment
sierra-dev init

# Create named environment
sierra-dev init my_osint_tools

# Force recreate existing
sierra-dev init my_project --force

What It Creates:

Text Only
1
2
3
4
my_project/
├── scripts/        # Your source invokers
├── config.yaml     # Configuration file
└── source          # Package metadata


clean - Clean EnvironmentLink

Remove generated files from an environment.

Syntax:

Bash
sierra-dev clean [--env ENV_NAME]

What It Removes: - config.yaml - __pycache__ directories - .pytest_cache directories

Examples:

Bash
1
2
3
4
5
# Clean default environment
sierra-dev clean

# Clean specific environment
sierra-dev clean --env test_env


🏗️ Build CommandsLink

build - Compile InvokersLink

Compile source invokers into standalone scripts.

Syntax:

Bash
sierra-dev build [--env ENV_NAME] [-v]

Options: - --env - Environment to build (default: default_env) - -v, --verbose - Show detailed logs

Examples:

Bash
1
2
3
4
5
6
7
8
# Build with default settings
sierra-dev build

# Build with debug output
sierra-dev build --verbose

# Build specific environment
sierra-dev build --env production

Process:

graph LR
    A[Source Scripts] -->|Validate| B[Type Check]
    B -->|Transform| C[Generate CLI]
    C -->|Bundle| D[Standalone Scripts]
    D --> E[Update config.yaml]

    style A fill:#bc13fe20
    style D fill:#00f3ff20

Output: - Compiled scripts in ENV/invokers/ - Updated ENV/config.yaml - Installed dependencies in ENV/venv/


check - Validate InvokersLink

Run comprehensive validation checks without building.

Syntax:

Bash
sierra-dev check [--env ENV_NAME] [-v]

Checks: - ✅ Type annotations present - ✅ Parameter validation rules - ✅ YAML-safe names and descriptions - ✅ Entry point exists - ✅ Dependencies resolvable

Examples:

Bash
1
2
3
4
5
# Check current environment
sierra-dev check

# Check with details
sierra-dev check --verbose

Output Example:

Text Only
✨ All checks passed! Your invokers are healthy.

# Or if issues found:
❌ ERRORS:
[ERROR] invoker: my-tool
  Invalid invoker name 'my-tool'
  💡 Suggestion: Use only lowercase letters, numbers, and underscores

⚠️ WARNINGS:
[WARNING] parameter: my_tool.target
  No description provided


health - Environment HealthLink

Check overall health of your Sierra environment.

Syntax:

Bash
sierra-dev health [--env ENV_NAME] [-v]

Checks: - Scripts directory exists - Virtual environment valid - Dependencies installed - Config file valid

Examples:

Bash
sierra-dev health

Output:

Text Only
✅ Health Status: HEALTHY

Invokers: 5
Errors: 0
Warnings: 2

Environment Checks:
  ✅ Scripts Directory
  ✅ Virtual Environment
  ✅ Config File
  ✅ Dependencies


📦 Package Manager CommandsLink

repo add - Add RepositoryLink

Add a GitHub repository as a package source.

Syntax:

Bash
sierra-dev repo add <url> [--name NAME] [--branch BRANCH] [--priority PRIORITY]

Arguments: - url - GitHub repository URL - --name - Custom name for source - --branch - Git branch (default: main) - --priority - Source priority (default: 10, lower = higher priority)

Examples:

Bash
1
2
3
4
5
6
7
8
# Add official repository
sierra-dev repo add https://github.com/xsyncio/sierra-invokers

# Add with custom name
sierra-dev repo add https://github.com/user/tools --name custom-tools

# Add development branch
sierra-dev repo add https://github.com/user/tools --branch dev


repo list - List RepositoriesLink

Show all configured package sources.

Syntax:

Bash
sierra-dev repo list

Output:

Text Only
📦 Configured Repositories:

1. xsyncio/sierra-invokers (priority: 10) ✅ enabled
   URL: https://github.com/xsyncio/sierra-invokers
   Packages: 15
   Cached: 2024-11-26 10:30:15

2. custom-tools (priority: 20) ✅ enabled  
   URL: https://github.com/user/tools
   Packages: Not cached yet


repo update - Update RegistryLink

Update package registry from repositories.

Syntax:

Bash
sierra-dev repo update [source]

Arguments: - source - Specific source to update (optional)

Examples:

Bash
1
2
3
4
5
# Update all sources
sierra-dev repo update

# Update specific source
sierra-dev repo update xsyncio/sierra-invokers


repo remove - Remove RepositoryLink

Remove a package source.

Syntax:

Bash
sierra-dev repo remove <name>

Examples:

Bash
sierra-dev repo remove custom-tools


search - Search PackagesLink

Find packages across all repositories.

Syntax:

Bash
sierra-dev search <query> [--tag TAG] [--category CATEGORY] [--source SOURCE]

Options: - --tag - Filter by tag - --category - Filter by category - --source - Filter by source

Examples:

Bash
# Search for domain tools
sierra-dev search domain

# Filter by category
sierra-dev search "" --category network

# Filter by tag
sierra-dev search osint --tag investigation

# Combine filters
sierra-dev search "" --category web --source xsyncio/sierra-invokers

Output:

Text Only
📦 Search Results (3 packages):

whois-lookup v1.2.0
  Comprehensive WHOIS lookup for domains and IPs
  Category: domain | Tags: osint, whois

dns-analyzer v1.0.5
  Advanced DNS record analysis
  Category: domain | Tags: dns, investigation

subdomain-enum v2.0.1
  Subdomain enumeration tool
  Category: domain | Tags: recon, osint


info - Package InformationLink

Show detailed information about a package.

Syntax:

Bash
sierra-dev info <package>

Examples:

Bash
sierra-dev info whois-lookup

Output:

Text Only
Package: whois-lookup
Version: 1.2.0
Category: domain
Source: xsyncio/sierra-invokers

Description:
  Comprehensive WHOIS information retrieval for
  domains and IP addresses.

Tags: osint, whois, domain, investigation

Dependencies:
  - requests
  - dnspython

Installation:
  sierra-dev install whois-lookup


install - Install PackageLink

Install packages into your environment.

Syntax:

Bash
sierra-dev install <packages...> [--env ENV] [--force] [--skip-validation]

Options: - --env - Target environment (default: test_env) - --force - Force reinstall - --skip-validation - Skip type safety checks

Examples:

Bash
# Install single package
sierra-dev install whois-lookup

# Install multiple packages
sierra-dev install whois-lookup dns-analyzer port-scanner

# Force reinstall
sierra-dev install whois-lookup --force

# Install to specific environment
sierra-dev install whois-lookup --env production

# Skip validation (not recommended)
sierra-dev install whois-lookup --skip-validation

Process: 1. Downloads package from source 2. Validates type safety (unless skipped) 3. Installs to ENV/scripts/ 4. Updates package metadata

Important: After installing, run sierra-dev build to compile!


list - List PackagesLink

List available or installed packages.

Syntax:

Bash
sierra-dev list [--installed] [--env ENV]

Options: - --installed - Show only installed packages - --env - Environment to check (default: test_env)

Examples:

Bash
1
2
3
4
5
6
7
8
# List all available packages
sierra-dev list

# List installed packages
sierra-dev list --installed

# Check specific environment
sierra-dev list --installed --env production

Output (Available):

Text Only
📦 Available Packages (15 total):

DOMAIN:
  whois-lookup v1.2.0
  dns-analyzer v1.0.5
  subdomain-enum v2.0.1

NETWORK:
  port-scanner v3.1.0
  ip-intelligence v1.5.2

Output (Installed):

Text Only
1
2
3
4
5
6
7
8
9
📦 Installed Packages (3):

whois-lookup v1.2.0
  Installed: 2024-11-26
  Source: xsyncio/sierra-invokers

dns-analyzer v1.0.5
  Installed: 2024-11-25
  Source: xsyncio/sierra-invokers


update - Update PackagesLink

Update installed packages to latest versions.

Syntax:

Bash
sierra-dev update [package] [--all] [--env ENV]

Options: - --all - Update all packages - --env - Environment to update (default: test_env)

Examples:

Bash
1
2
3
4
5
6
7
8
# Update specific package
sierra-dev update whois-lookup

# Update all packages
sierra-dev update --all

# Update in specific environment
sierra-dev update --all --env production

Output:

Text Only
🔄 Checking for updates...

📦 Updating 2 package(s)...

whois-lookup: 1.2.0 → 1.3.0
  ✅ Updated

dns-analyzer: 1.0.5 (up to date)

✅ Successfully updated 1/2 packages
🔨 Run 'sierra-dev build' to rebuild


upgradable - List UpgradableLink

Show packages with available updates.

Syntax:

Bash
sierra-dev upgradable [--env ENV]

Examples:

Bash
sierra-dev upgradable

Output:

Text Only
📦 Upgradable Packages (2):

whois-lookup
  Installed: 1.2.0
  Available: 1.3.0
  Source: xsyncio/sierra-invokers

port-scanner
  Installed: 3.0.0
  Available: 3.1.0
  Source: xsyncio/sierra-invokers

Run 'sierra-dev update --all' to upgrade all packages


remove - Uninstall PackageLink

Remove an installed package.

Syntax:

Bash
sierra-dev remove <package> [--env ENV]

Examples:

Bash
1
2
3
4
5
# Remove package
sierra-dev remove whois-lookup

# Remove from specific environment
sierra-dev remove whois-lookup --env production

Output:

Text Only
1
2
3
4
🗑️  Removing whois-lookup...
✅ Removed successfully

🔨 Run 'sierra-dev build' to rebuild


💡 Common WorkflowsLink

Starting a New ProjectLink

Bash
# 1. Initialize environment
sierra-dev init my_investigation

# 2. Add package sources
sierra-dev repo add https://github.com/xsyncio/sierra-invokers

# 3. Search for tools
sierra-dev search osint

# 4. Install tools
sierra-dev install whois-lookup dns-analyzer

# 5. Build environment
sierra-dev build --env my_investigation

Developing an InvokerLink

Bash
# 1. Create environment
sierra-dev init dev_env

# 2. Write invoker in dev_env/scripts/my_tool.py
# (use your text editor)

# 3. Validate
sierra-dev check --env dev_env

# 4. Build
sierra-dev build --env dev_env --verbose

# 5. Test
dev_env/venv/bin/python dev_env/invokers/my_tool.py --help

Maintaining PackagesLink

Bash
# Check for updates
sierra-dev upgradable

# Update all
sierra-dev update --all

# Rebuild
sierra-dev build

# Verify health
sierra-dev health

🔧 Advanced UsageLink

Environment VariablesLink

Bash
1
2
3
4
5
# Set default environment
export SIERRA_ENV=production

# Use custom config location
export SIERRA_CONFIG=/path/to/config

Chaining CommandsLink

Bash
# Install and build in one go
sierra-dev install whois-lookup && sierra-dev build

ScriptingLink

Bash
1
2
3
4
5
6
7
#!/bin/bash
# Auto-update script

sierra-dev repo update
sierra-dev update --all
sierra-dev build
sierra-dev check

🚨 Exit CodesLink

Commands return standard exit codes:

Code Meaning
0 Success
1 Error
130 Interrupted (Ctrl+C)

Use in scripts:

Bash
1
2
3
4
5
6
if sierra-dev build --env prod; then
    echo "Build successful"
else
    echo "Build failed"
    exit 1
fi