Waldek Mastykarz

gitload

开发编程v1.0.1
作者:Waldek Mastykarz更新于 2026-05-16共 2 个版本 · 最新版本发布于 2026-05-16@clawhub_waldekmastykarz/gitload
Git 辅助#GitHub

据 AlphaMoat 统计,截至 2026-09,gitload 累计下载 4,204 次、获 3 个星标,在全部 5,078 个 AI 技能中排名第 2,380 位,在「开发编程」分类(577 个)中排名第 306 位。

累计安装
247
累计下载
4,204
星标
3
全站排名
#2,380
全站前 47% · 「开发编程」前 54%
平台累计安装累计下载星标评论
ClawHub ↗1333,9333-
SkillHub ↗2474,2043—

各平台的计数口径不同,统计时间不一致。

这个技能是做什么的

通过 gitload CLI 从 GitHub URL 下载指定文件、文件夹或仓库内容,无需获取完整 Git 历史。下载前核对仓库所有者、路径和分支,避免从不可信来源执行代码。

资料发布于 2026-10-27

可以用来做什么

  • 从 GitHub 获取指定目录
  • 下载仓库中的特定文件

什么时候用

  • 需要只获取仓库部分内容时
  • 检查下载来源和目标路径时

示例提示词

以下是根据技能文档生成的示例,不代表实际运行结果。

从这个 GitHub 仓库下载指定文件夹,不要运行其中代码。
先展示仓库、分支和目标路径供我检查。

月度数据趋势

累计下载4,204
2,8493,5774,3042026-03 · 累计下载 2,9492026-05 · 累计下载 3,4292026-06 · 累计下载 3,5682026-07 · 累计下载 3,7932026-08 · 累计下载 3,8872026-09 · 累计下载 4,20426-0326-09
星标3
2342026-03 · 星标 32026-05 · 星标 32026-06 · 星标 32026-07 · 星标 32026-08 · 星标 32026-09 · 星标 326-0326-09

2026-09 起统计方法调整:同名技能按作者分别统计,并覆盖全部技能。图中虚线为调整前的月份,与之后的数据不直接比较,也不计算跨越调整的增长。

月份累计下载环比星标
2026-094,204—3
2026-083,887+2.5%3
2026-073,793+6.3%3
2026-063,568+4.1%3
2026-053,429—3
2026-032,949—3

SKILL.md 原文

以下是作者发布的原始文件,按纯文本显示,本站未做修改或审核;其中的链接不可点击,命令请核实后再运行。抓取于 2026-10-23。

3.8 KB · ClawHub v1.0.1
---
name: gitload
description: This skill should be used when the user asks to "download files from GitHub", "fetch a folder from a repo", "grab code from GitHub", "download a GitHub repository", "get files from a GitHub URL", "clone just a folder", or needs to download specific files/folders from GitHub without cloning the entire repo.
---

# gitload

Download files, folders, or entire repos from GitHub URLs using the gitload CLI.

## When to Use
展开全部(共 147 行)

Use gitload when:
- Downloading a specific folder from a repo (not the whole repo)
- Fetching a single file from GitHub
- Downloading repo contents without git history
- Creating a ZIP archive of GitHub content
- Accessing private repos with authentication

Do NOT use gitload when:
- Full git history is needed (use `git clone` instead)
- The repo is already cloned locally
- Working with non-GitHub repositories

## Prerequisites

Run gitload via npx (no install needed):
```bash
npx gitload-cli https://github.com/user/repo
```

Or install globally:
```bash
npm install -g gitload-cli
```

## Basic Usage

### Download entire repo
```bash
gitload https://github.com/user/repo
```
Creates a `repo/` folder in the current directory.

### Download a specific folder
```bash
gitload https://github.com/user/repo/tree/main/src/components
```
Creates a `components/` folder with just that folder's contents.

### Download a single file
```bash
gitload https://github.com/user/repo/blob/main/README.md
```

### Download to a custom location
```bash
gitload https://github.com/user/repo/tree/main/src -o ./my-source
```

### Download contents flat to current directory
```bash
gitload https://github.com/user/repo/tree/main/templates -o .
```

### Download as ZIP
```bash
gitload https://github.com/user/repo -z ./repo.zip
```

## Authentication (for private repos or rate limits)

### Using gh CLI (recommended)
```bash
gitload https://github.com/user/private-repo --gh
```
Requires prior `gh auth login`.

### Using explicit token
```bash
gitload https://github.com/user/repo --token ghp_xxxx
```

### Using environment variable
```bash
export GITHUB_TOKEN=ghp_xxxx
gitload https://github.com/user/repo
```

**Token priority:** `--token` > `GITHUB_TOKEN` > `--gh`

## URL Formats

gitload accepts standard GitHub URLs:
- **Repo root:** `https://github.com/user/repo`
- **Folder:** `https://github.com/user/repo/tree/branch/path/to/folder`
- **File:** `https://github.com/user/repo/blob/branch/path/to/file.ext`

## Common Patterns

### Scaffold from a template folder
```bash
gitload https://github.com/org/templates/tree/main/react-starter -o ./my-app
cd my-app && npm install
```

### Grab example code
```bash
gitload https://github.com/org/examples/tree/main/authentication
```

### Download docs for offline reading
```bash
gitload https://github.com/org/project/tree/main/docs -z ./docs.zip
```

### Fetch a single config file
```bash
gitload https://github.com/org/configs/blob/main/.eslintrc.json -o .
```

## Options Reference

| Option | Description |
|--------|-------------|
| `-o, --output <dir>` | Output directory (default: folder named after URL path) |
| `-z, --zip <path>` | Save as ZIP file at the specified path |
| `-t, --token <token>` | GitHub personal access token |
| `--gh` | Use token from gh CLI |
| `--no-color` | Disable colored output |
| `-h, --help` | Display help |
| `-V, --version` | Output version |

## Error Handling

If gitload fails:
1. **404 errors:** Verify the URL exists and is accessible
2. **Rate limit errors:** Add authentication with `--gh` or `--token`
3. **Permission errors:** For private repos, ensure token has `repo` scope
4. **Network errors:** Check internet connectivity

## Notes

- gitload downloads content via GitHub's API, not git protocol
- No git history is preserved (use `git clone` if history is needed)
- Large repos may take time; consider downloading specific folders
- Output directory is created if it doesn't exist

「开发编程」分类下的热门技能

数据月份:2026-09 · 下载/星标/安装数聚合自公开技能注册库(ClawHub、SkillHub),按月更新。口径说明见数据方法。