# scrapix-cli

> A TypeScript-based CLI Application for scraping Google images

Latest version **0.1.8** (published 2021-10-15) · ISC license · 0 weekly downloads

## Install

```sh
npm install scrapix-cli
pnpm add scrapix-cli
yarn add scrapix-cli
bun add scrapix-cli
```

Provides the command `scrapix`.

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.8 |
| Published | 2021-10-15 |
| First published | 2021-08-16 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 7 |
| Unpacked size | 22.7 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | theblackdove |
| Maintainers | simiokunowo |
| Keywords | image-scraping, typescript, cli, headless |

## Links

- npm: https://www.npmjs.com/package/scrapix-cli
- Repository: https://github.com/rexsimiloluwah/scrapix-cli
- Homepage: https://github.com/rexsimiloluwah/scrapix-cli#readme
- Issues: https://github.com/rexsimiloluwah/scrapix-cli/issues
- npm.io page: https://npm.io/package/scrapix-cli

## Dependencies (7)

- [chalk](https://npm.io/package/chalk.md) ^4.1.2
- [clear](https://npm.io/package/clear.md) ^0.1.0
- [figlet](https://npm.io/package/figlet.md) ^1.5.0
- [request](https://npm.io/package/request.md) ^2.88.2
- [inquirer](https://npm.io/package/inquirer.md) ^8.1.2
- [commander](https://npm.io/package/commander.md) ^8.1.0
- [images-scraper](https://npm.io/package/images-scraper.md) ^6.3.0

## Alternatives

- [@salesforce/cli](https://npm.io/package/@salesforce/cli.md) — 389.7K weekly downloads
- [@mintlify/cli](https://npm.io/package/@mintlify/cli.md) — 208.9K weekly downloads
- [@grafana/e2e-selectors](https://npm.io/package/@grafana/e2e-selectors.md) — 128.7K weekly downloads
- [mintlify](https://npm.io/package/mintlify.md) — 112.0K weekly downloads
- [@intlayer/cli](https://npm.io/package/@intlayer/cli.md) — 22.8K weekly downloads

## Recent versions

- 0.1.8 (latest) — 2021-10-15
- 0.1.7 — 2021-08-17
- 0.1.3 — 2021-08-16
- 0.1.2 — 2021-08-16
- 0.1.1 — 2021-08-16
- 0.0.1 — 2021-08-16
- 1.0.1 — 2021-08-16

## README

<h1 align="center">
  Scrapix
</h1>
<h4 align="center">
    A TypeScript-based CLI tool for scraping and downloading Google images 🚀.
</h4>

<div align="center">
  <img src="https://badgen.net/npm/v/make-cli-tool?icon=npm" />
  <img src="https://badgen.net/github/last-commit/sajmoni/make-cli-tool?icon=github" />
</div>

[![experimental](http://badges.github.io/stability-badges/dist/experimental.svg)](http://github.com/badges/stability-badges)

### Description
`Scrapix` is an interactive CLI for scraping and downloading Google images easily. The core of this CLI is the [images-scraper](https://www.npmjs.com/package/images-scraper) package, which uses a puppeteer-based headless browser to automatically search and return the URLs of the images. This `scrapix` CLI can help developers and non-developers to build image datasets for computer vision tasks i.e. image classification, object detection, face recognition. 

### Installation
```bash
$ npm install -g scrapix-cli
```

### To resolve `puppeteer` installation issues on Linux based OS: -
```bash
$ sudo npm install -g scrapix-cli --unsafe-perm=true
```

### Usage 
To start the CLI, Type the `scrapix` command in your CMD or terminal: -
```bash
$ scrapix
```
### Modes 
| default | The search keywords are defined in the terminal directly |
|---------|----------------------------------------------------------|
| file    | The search keywords are defined in a .json file.         |

##### Default mode: usage
Required Parameters: -
- `keywords`: - The names of images you want to download seperated by commas (i.e. roses,daisy,hibiscus)
- `number`: - The number of images you want to download

##### File mode: usage
Required parameters: -
- Name of .json file in the base directory to load the keyword and number of images to be scraped and downloaded for each keyword.

##### Structure of the .json file content
```json
{
    "images": [
        {"keyword": "roses", "number":20},
        {"keyword":"daisy", "number":25},
        {"keyword":"hibiscus", "number":30},
    ]
}
```

[View Video Demonstration](https://www.youtube.com/watch?v=3mRXiu-i4TY)

### TODOS
- Image validation 
- Support for custom image processing actions i.e. resizing, compression
- Improve error handling
- Provide support for other search engines i.e. Bing, Wikipedia
- Improve general performance
- Clean code and develop a better documentation

### Contributing Guide
Coming soon

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