Skip to content
init-pixi-project logo

Initialize Pixi Project

init-pixi-project

Initialize and scaffold a new Pixi-managed Python project, or upgrade an existing one. Use when the user explicitly mentions "init", "initialize", or "setup" in conjunction with "pixi". Handles existing projects by prompting for confirmation before merging.

SKILL.md

Full skill instructions

Initialize Pixi Project

References

Workflow

1. Safety Check & Parameters

  1. Check for Existing Artifacts: Look for pixi.lock, pixi.toml, or a pyproject.toml containing [tool.pixi].
  2. Prompt if Exists: If any of these exist, PAUSE and ASK the user:

    "Existing Pixi configuration detected. Proceeding will scaffold the directory structure and attempt to merge standard dependencies (scipy, ruff, etc.) into the current environment. This might affect existing functionality. Do you want to proceed?"

  3. Abort if Rejected: If the user declines, stop.
  4. Determine Parameters (if proceeding):
    • Format: Default to pyproject unless user specifies otherwise.
    • Python Version: Target one minor version behind latest stable (e.g., 3.12).

2. Initialization (Merge/​Create)

Attempt to initialize Pixi.

  • Run: pixi init [PATH] --format [pyproject|pixi] -c conda-forge
  • Handle Existing:
    • If the command fails because the project is already initialized, verify that [tool.pixi] exists in the manifest.
    • If it exists, skip to the next step.
    • If pyproject.toml exists but lacks Pixi config, the agent should try to append the default Pixi configuration or ask the user if pixi init didn't do it automatically.

3. Post-Initialization Configuration

A. Handle Custom Project Name

If the user specified a project name different from the current directory name:

  1. Rename Source: mv src/<dir_name> src/<project_name>
  2. Update Manifest: Edit pyproject.toml to replace the old name with the new one in:
    • [project] name = "..."
    • [tool.pixi.pypi-dependencies] section (rename the key).
B. Scaffolding (Idempotent)

Run the scaffolding script. Pass the project name if custom.

python <path_to_skill>/​scripts/​scaffold_structure.py [PATH] --package-name <project_name>
C. Gitignore

Check .gitignore. Append the following if not present:

.pixi/
tmp/
.git/
D. Install Python and Dependencies (Smart Merge)
  1. Check Python: Check if python is already a dependency.
    • If yes, respect the existing version (or ask user if they want to override).
    • If no, add it: pixi add python=<version>
  2. Add Standard Packages:
    • Attempt to add the standard stack:
      pixi add --pypi scipy mdutils ruff mkdocs-material mypy attrs omegaconf imageio
      
    • Conflict Handling: If pixi add fails due to conflicts with existing packages, try to resolve by:
      • Installing the non-conflicting subset.
      • Reporting specific conflicts to the user and asking for guidance.
  3. Finalize: Run pixi install.

4. Verification

  • Verify the environment is usable (pixi shell works).
  • Verify directory structure.

More skills from majiayu000

xiaohongshu logo
majiayu000/claude-arsenal

xiaohongshu

xiaohongshu

286 148
View
agent-task-conductor logo
majiayu000/claude-skill-registry

agent-task-conductor

Conduct multi-agent task orchestration and workflow coordination.

663 1
View
conductor-setup logo
majiayu000/claude-skill-registry

conductor-setup

Initialize project with Conductor artifacts (product definition,

663 1
View
animation-designer logo
majiayu000/claude-skill-registry

animation-designer

Expert in web animations, transitions, and motion design using Framer Motion and CSS

663 1
View
diagramming logo
majiayu000/claude-skill-registry

diagramming

Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...

663 1
View
h3-pg logo
majiayu000/claude-skill-registry-data

h3-pg

PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.

23 1
View
conductor-development logo
majiayu000/claude-skill-registry

conductor-development

Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...

663 1
View
conductor-status logo
majiayu000/claude-skill-registry

conductor-status

Display project status, active tracks, and next actions

663 1
View
dockerization logo
majiayu000/claude-skill-registry

dockerization

Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.

663 1
View

Popular AI tools

Kaiber logo
Video

Kaiber

Generate, edit, and beat-sync AI video with leading models in one workspace.

Paid
View
Vimcal logo
Productivity

Vimcal

The world's fastest calendar for remote work

Free
View

Transform Your Design with AI Designer by ImgCreator.ai

Freemium
View
Akool AI logo
Content & writing

Akool AI

Revolutionizing Video Production with AI-Powered Creativity

Paid
View

Extend an image past the frame and let AI fill the new aspect ratio.

Freemium
View
StarByFace logo
Security

StarByFace

Discover your celebrity doppelgänger with StarByFace!

Free
View
C

ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.

Freemium
View
Opus Clip logo
Coding & apps

Opus Clip

Opus.ai: Revolutionize Your Web Experience

Free
View