install-chromedriver/README.md
2024-12-12 10:30:23 -07:00

69 lines
1.7 KiB
Markdown

# Install Chromedriver
A simple CLI utility to install the matching Chromedriver for your currently installed version of Google Chrome. This tool installs the appropriate version of Chromedriver either in your system's `PATH` or inside your virtual environment if one is enabled.
## Running
Running this tool is pretty simple- in your terminal, run this command
```
install-chromedriver
```
This will install the chromedriver matching your system chrome in either your `PATH` or in the currently active virtual environment.
If you want to install in a specific directory, pass the `--path` parameter pointing to the location you would like the chromedriver.
```
install-chromedriver --path /path/to/install/location
```
## Features
- Automatically finds the installed version of Google Chrome.
- Installs the matching version of Chromedriver.
- Can install Chromedriver globally or in a virtual environment.
## Requirements
- Google Chrome installed on the system.
- Poetry installed either on your system or in a virtualenv
## Installation
You can install this utility as a Python package via pip via `pip install install-chromedriver -i https://monupypi.herokuapp.com`, or by downloading the binary for your operating system.
### Build from Source
1. First, install Poetry if you don't have it:
```
curl -sSL https://install.python-poetry.org | python3 -
```
2. Clone the repository:
```
git clone https://git.djg.dev/dahjah/install-chromedriver
cd install-chromedriver
```
3. Install:
```
poetry install
```
### Packaging
Building packages is simple- just run
```
poetry run build-all
```
To build just python package and wheel, run
```
poetry build
```
To build just the system binary, run
```
poetry run build-executable
```