← 返回
开发者工具

Environment & Package Manager

x-env is x-cmd's environment and package management module for installing and managing third-party software, programming language runtimes, and command-line...
x-env 是 x-cmd 的环境与包管理模块,用于安装和管理第三方软件、编程语言运行时及命令行工具。
lunrenyi
开发者工具 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 1
Stars
📥 607
下载
💾 12
安装
1
版本
#latest

概述

x env - Environment & Package Manager

Prerequisites

  1. Load x-cmd before use:

```bash

. ~/.x-cmd.root/X

```

  1. x-cmd not installed? → data/install.md

Core Concepts

  • try: Temporarily use software in current shell session (only valid for current terminal)
  • use: Permanently install software to user environment (persists after terminal restart)
  • untry: Cancel temporarily tried software in current session
  • unuse: Remove installed software from user environment
  • upgrade: Upgrade installed software versions

Core Functions

  • List available versions: x env la
  • List installed packages: x env ls, x env ll
  • Temporary use (try): x env try [=]
  • Permanent install (use): x env use [=]
  • Remove package: x env unuse
  • Upgrade package: x env upgrade
  • Cleanup packages: x env gc
  • Find command path: x env which
  • Check dependencies: x env depend

Usage Examples

Install packages

x env use node              # Install default version of node
x env use python            # Install default version of python
x env use go=v1.21.0        # Install specific version
x env use node python go    # Install multiple packages

Temporary use (current shell session only)

x env try node              # Use default node in current session
x env try bun go=v1.17.13   # Use multiple packages with versions
x env untry node            # Cancel temporary use

Version management

x env use --upgrade --all   # Upgrade all installed packages
x env use --upgrade jq yq   # Upgrade specific packages
x env upgrade node python   # Upgrade packages (shorthand)

List and search

x env la node               # List all available node versions
x env ls                    # List packages in use
x env ll                    # List all installed packages
x env which node            # Show node installation path

Cleanup

x env gc jq yq              # Remove specified packages and orphans

Common Scenarios

  • Install node: x env use node
  • Install python: x env use python
  • Install go: x env use go
  • Install jq: x env use jq
  • Install specific version: x env use node=v18.12.0
  • Temporary try: x env try node
  • Upgrade all: x env upgrade --all
  • Find path: x env which node

Get Help

Run x env --help for full help documentation.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-19 21:53 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

developer-tools

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 920 📥 185,715
developer-tools

CodeConductor.ai

larsonreever
AI驱动平台,提供快速全栈开发、智能体、工作流自动化及低代码AI集成的可扩展产品创建。
★ 65 📥 179,778
developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 666 📥 323,747