mirror of
https://github.com/runkids/skillshare.git
synced 2026-11-19 02:17:09 +00:00
Init now creates an initial commit (including .gitignore) so that push/pull work immediately after setup. When a remote is configured, init fetches and auto-pulls existing skills from the remote. - Always create initial commit in doGitInit (fixes stale untracked .gitignore blocking pull) - Add ensureGitIdentity: set repo-local fallback when git user.name is not configured, with hint to set global config - Add tryPullAfterRemoteSetup: fetch remote after adding origin, auto-pull if remote has content and local is empty - Add hintGitRemoteError: context-aware hints for SSH, URL, and network errors in push/pull - Show Pro tip only when built-in skill is installed - Sandbox: add --bare mode (skip auto-init), --volumes for down (full reset), and sandbox-reset / sandbox:reset targets - Docs: update init flow diagram, cross-machine-sync guide, push/pull prerequisites, getting-started, troubleshooting
4.6 KiB
4.6 KiB
sidebar_position
| sidebar_position |
|---|
| 1 |
push
Commit and push source to git remote.
skillshare push # Auto-generated message
skillshare push -m "Add pdf" # Custom message
skillshare push --dry-run # Preview
What Happens
┌─────────────────────────────────────────────────────────────────┐
│ skillshare push -m "Add pdf skill" │
└─────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────┐
│ 1. Check repository status │
│ → Source is a git repo: ✓ │
│ → Remote configured: ✓ │
└─────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────┐
│ 2. Stage all changes │
│ → git add -A │
└─────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────┐
│ 3. Commit │
│ → git commit -m "Add pdf skill" │
└─────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────┐
│ 4. Push to remote │
│ → git push │
└─────────────────────────────────────────────────────────────────┘
Options
| Flag | Description |
|---|---|
-m, --message <msg> |
Commit message (default: "Update skills") |
--dry-run, -n |
Preview without making changes |
Prerequisites
Your source directory must be a git repository with a remote:
# Set up during init (recommended):
skillshare init --remote git@github.com:you/my-skills.git
# Or add remote to existing setup:
skillshare init --remote git@github.com:you/my-skills.git
Init automatically creates the initial commit, so push works immediately after setup.
Examples
# Quick push with auto message
skillshare push
# Custom commit message
skillshare push -m "Add commit-commands skill"
# Preview what would be pushed
skillshare push --dry-run
Conflict Handling
If the remote has newer commits:
$ skillshare push
Push failed
Remote may have newer changes
Run: skillshare pull
Then: skillshare push
Solution:
skillshare pull # Get remote changes
skillshare push # Push your changes
Workflow
Typical workflow for sharing skills:
# 1. Make changes to skills
# 2. Push to remote
skillshare push -m "Update my-skill"
# On another machine:
skillshare pull # Gets changes and syncs
Related
- pull — Pull from remote
- sync — Sync to local targets
- Cross-Machine Sync — Full setup