← 全部工具

bolens/ps-profile

热度 65 更新于 DevOps 与云

Modular cross-platform PowerShell profile with 130+ lazy-loaded fragments for dev tooling, data/document conversion, cloud & containers, and on-demand command access.

githubauto-collected

安装

暂未验证可直接使用的安装命令,请查看项目官方文档或 Release。

PowerShell Profile

⚠️ WARNING: This project is under active development and may be unstable at any time. Breaking changes, incomplete features, and bugs that prevent normal operation can occur without notice. Use at your own risk. Pin a commit if you rely on it, and expect to tune fragments for your environment.

A modular, cross-platform PowerShell profile that turns your shell into a lazy-loaded toolkit for daily development work.

Functionality lives in 130+ fragments under profile.d/—each focused on one concern (Git, containers, language runtimes, cloud CLIs, conversion pipelines, and more)—and loads only when you need it.

What This Project Does

This is not a minimal prompt-and-alias dotfile. It is a maintainable profile framework built around three ideas:

  • Modular fragments — Each feature area is a small, idempotent script in profile.d/ with explicit dependencies, environment presets, and optional disable flags via .profile-fragments.json.
  • Fast startup — Expensive work is deferred behind Enable- helpers, command-existence caches, and optional batch/parallel loading so interactive sessions stay responsive.
  • On-demand command access — Functions and aliases register in a fragment command registry so commands can load their fragment automatically

(including from -NoProfile sessions and generated standalone wrappers). See docs/guides/FRAGMENTCOMMANDACCESS.md.

In practice the profile bundles helpers for:

  • Development workflows — Git, modern CLI tools, language runtimes (Go, Rust, Python, Java, Node, and more), build/test runners, and editor integrations
  • Cloud and infrastructure — AWS, Azure, GCP, Kubernetes, Terraform, Ansible, and related tooling
  • Containers — Docker/Podman helpers with auto-detection
  • Data and document conversion — JSON/YAML/CSV/XML, columnar and binary formats, Markdown/LaTeX notes, media transforms, ISBN/bibliography utilities, QR codes, and related pipelines under profile.d/conversion-modules/
  • Shell quality of life — PSReadLine, oh-my-posh/Starship prompts, history, diagnostics, and system monitoring

The repo also ships the tooling that keeps the profile maintainable: Pester unit/integration/performance tests, PSScriptAnalyzer linting, startup benchmarks, auto-generated API docs (docs/api/), and 80+ quality tasks via Task, Just, Make, or npm.

Current scale: see docs/api/README.md for live function and alias counts (currently 2,300+ functions and 1,400+ aliases).

Quick Start

Clone this repository to your PowerShell profile path, then reload:

# Windows (PowerShell 7+)
git clone https://github.com/bolens/ps-profile.git $HOME\Documents\PowerShell

# Linux / macOS
git clone https://github.com/bolens/ps-profile.git ~/.config/powershell

# Reload profile
. $PROFILE

Optional: load a slimmer preset before sourcing (see PROFILEREADME.md):

$env:PS_PROFILE_ENVIRONMENT = 'minimal'   # or development, cloud, ci, …
. $PROFILE

Features