AgentSkillsCN

deploy

用于生产环境发布的部署命令,涵盖预检流程与部署执行环节。

SKILL.md
--- frontmatter
name: deploy
description: Deployment command for production releases. Pre-flight checks and deployment execution.

/deploy - Production Deployment

$ARGUMENTS


Purpose

This command handles production deployment with pre-flight checks, deployment execution, and verification.


Sub-commands

code
/deploy            - Interactive deployment wizard
/deploy check      - Run pre-deployment checks only
/deploy preview    - Deploy to preview/staging
/deploy production - Deploy to production
/deploy rollback   - Rollback to previous version

Pre-Deployment Checklist

Before any deployment:

markdown
## 🚀 Pre-Deploy Checklist

### Code Quality
- [ ] No TypeScript errors (`npx tsc --noEmit`)
- [ ] ESLint passing (`npx eslint .`)
- [ ] All tests passing (`npm test`)

### Security
- [ ] No hardcoded secrets
- [ ] Environment variables documented
- [ ] Dependencies audited (`npm audit`)

### Performance
- [ ] Bundle size acceptable
- [ ] No console.log statements
- [ ] Images optimized

### Documentation
- [ ] README updated
- [ ] CHANGELOG updated
- [ ] API docs current

### Ready to deploy? (y/n)

Deployment Flow

code
┌─────────────────┐
│  /deploy        │
└────────┬────────┘
         │
         ▼
┌─────────────────┐
│  Pre-flight     │
│  checks         │
└────────┬────────┘
         │
    Pass? ──No──► Fix issues
         │
        Yes
         │
         ▼
┌─────────────────┐
│  Build          │
│  application    │
└────────┬────────┘
         │
         ▼
┌─────────────────┐
│  Deploy to      │
│  platform       │
└────────┬────────┘
         │
         ▼
┌─────────────────┐
│  Health check   │
│  & verify       │
└────────┬────────┘
         │
         ▼
┌─────────────────┐
│  ✅ Complete    │
└─────────────────┘

Output Format

Successful Deploy

markdown
## 🚀 Deployment Complete

### Summary
- **Version:** v1.2.3
- **Environment:** production
- **Duration:** 47 seconds
- **Platform:** Vercel

### URLs
- 🌐 Production: https://app.example.com
- 📊 Dashboard: https://vercel.com/project

### What Changed
- Added user profile feature
- Fixed login bug
- Updated dependencies

### Health Check
✅ API responding (200 OK)
✅ Database connected
✅ All services healthy

Failed Deploy

markdown
## ❌ Deployment Failed

### Error
Build failed at step: TypeScript compilation

### Details

error TS2345: Argument of type 'string' is not assignable...

code

### Resolution
1. Fix TypeScript error in `src/services/user.ts:45`
2. Run `npm run build` locally to verify
3. Try `/deploy` again

### Rollback Available
Previous version (v1.2.2) is still active.
Run `/deploy rollback` if needed.

Platform Support

PlatformCommandNotes
Vercelvercel --prodAuto-detected for Next.js
Railwayrailway upNeeds Railway CLI
Fly.iofly deployNeeds flyctl
Dockerdocker compose up -dFor self-hosted

Examples

code
/deploy
/deploy check
/deploy preview
/deploy production --skip-tests
/deploy rollback

Built with ❤️ from Antigravity Kit & UXUI ProMax MIT © Vudovn