# dclone

> only clone part directories in git repo

Latest version **1.4.2** (published 2021-01-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install dclone
pnpm add dclone
yarn add dclone
bun add dclone
```

Provides the command `dclone`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.4.2 |
| Published | 2021-01-13 |
| First published | 2019-12-23 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 17.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | zhangyuang |
| Maintainers | zhangyuang |
| Keywords | git, clone |

## Links

- npm: https://www.npmjs.com/package/dclone
- Repository: https://github.com/ykfe/dclone
- Homepage: https://github.com/ykfe/dclone#readme
- Issues: https://github.com/ykfe/dclone/issues
- npm.io page: https://npm.io/package/dclone

## Dependencies (3)

- [shelljs](https://npm.io/package/shelljs.md) ^0.8.3
- [inquirer](https://npm.io/package/inquirer.md) ^7.0.1
- [optimist](https://npm.io/package/optimist.md) ^0.6.1

## Recent versions

- 1.4.2 (latest) — 2021-01-13
- 1.4.1 — 2020-10-29
- 1.4.0 — 2020-10-29
- 1.3.3 — 2020-04-17
- 1.3.2 — 2020-04-16
- 1.3.1 — 2020-04-13
- 1.3.0 — 2020-04-13
- 1.2.1 — 2020-04-10
- 1.2.0 — 2020-04-10
- 1.1.6 — 2020-03-21
- 1.1.5 — 2020-03-21
- 1.1.4 — 2020-03-21
- 1.1.3 — 2020-01-03
- 1.1.2 — 2019-12-25
- 1.1.1 — 2019-12-25
- … 9 more at https://npm.io/package/dclone/versions

## README

English | [简体中文](./README_zh-CN.md)

# Download specified directory in github/gitlab

<a href="https://circleci.com/gh/ykfe"><img src="https://img.shields.io/circleci/build/github/ykfe/dclone/master.svg" alt="Build Status"></a>
<a href="https://codecov.io/gh/ykfe/dclone"><img src="https://codecov.io/gh/ykfe/dclone/branch/master/graph/badge.svg" alt="Coverage Status"></a>
<a href="https://npmcharts.com/compare/dclone"><img src="https://img.shields.io/npm/dt/dclone" alt="download"></a>
<a href="https://standardjs.com"><img src="https://img.shields.io/badge/code_style-standard-brightgreen.svg" alt="standardjs"></a>
<a href="https://github.com/facebook/jest"><img src="https://img.shields.io/badge/tested_with-jest-99424f.svg" alt="License"></a>
<a href="https://github.com/ykfe/egg-react-ssr"><img src="https://img.shields.io/npm/l/vue.svg" alt="License"></a>
<img src="https://img.shields.io/badge/node-%3E=8-green.svg" alt="Node">

dclone is the simplest command for downloading specified directory or whole repo in github/gitlab (used depend on git), dclone can completely replace `git clone` and cut down download time

## Features

Let me introduce some awesome features in dclone

- quickly: you can only download single folder and cut down download time
- overall: dclone can download both github and gitlab
- simple: you only need copy http link in location

![](./image/time.jpg)

## How to use

it's very simple, you only need find github url of the directory，like `https://github.com/ykfe/egg-react-ssr/tree/dev/example/ssr-with-loadable`

![](./image/example.png)

```bash
$ npm i -g dclone
$ dclone https://github.com/ykfe/egg-react-ssr/tree/dev/example/ssr-with-loadable
```

You can also import dclone in files direct

```js
import { dclone } from 'dclone'

await dclone({
  dir: 'https://github.com/ykfe/egg-react-ssr/tree/dev/example/ssr-with-loadable'
})
```

![](./image/dg.png)

---
_Source: https://npm.io/package/dclone · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
