Install Ollama from a Python CLI.
Project description
ollama-installer
ollama-installer is the PyPI distribution name for a small Python package
that adds a python-ollama command. Its main goal is to install
Ollama from Python without stopping at a simple installer download.
When you run python-ollama install, the package downloads and executes the
official Ollama installation script for the current platform:
- Windows:
https://ollama.com/install.ps1 - Linux and macOS:
https://ollama.com/install.sh
Features
- Installs Ollama with a single command:
python-ollama install - Supports Windows, Linux, and macOS
- Supports version pinning with
--version - Supports
--dry-runso you can inspect the install plan first - Uses only the Python standard library
- Keeps the implementation compatible with Python 3
Installation
Install from the repository:
pip install .
Install from PyPI after publishing:
pip install ollama-installer
Install for the current user on Windows:
pip install --user .
If python-ollama is not found in cmd, add the user Scripts directory to
your PATH. On Windows this is usually:
%APPDATA%\Python\PythonXY\Scripts
Usage
Install the latest Ollama release:
python-ollama install
Install a specific version:
python-ollama install --version 0.7.2
Preview the resolved install plan without changing the system:
python-ollama install --dry-run
Request a custom install directory when the official installer supports it:
python-ollama install --install-dir C:\Ollama
Enable verbose installer output:
python-ollama install --debug
Development
Run the test suite:
python -m unittest discover -s tests -v
Build a wheel:
python -m pip wheel . -w dist
Repository Layout
python_ollama/: package source codetests/: unit testssetup.py: packaging metadata and CLI entry pointMANIFEST.in: source distribution file list
Notes
- Actual installation work is delegated to the official Ollama scripts.
- Administrator or sudo permissions may still be required by the host system.
- This project is an unofficial helper package for installing Ollama.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ollama_installer-0.1.0.tar.gz.
File metadata
- Download URL: ollama_installer-0.1.0.tar.gz
- Upload date:
- Size: 7.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
233b44dc9f8fe8c978dbf3b30c048a4424a735bfaead7f2a3844619b19fe178a
|
|
| MD5 |
e3a8e4854adaa44d79ae3021b1c49fc9
|
|
| BLAKE2b-256 |
d74c2f846c7e671120fe796dda3d3ceb0d066a85477da5443f75d7d714b907fd
|
File details
Details for the file ollama_installer-0.1.0-py3-none-any.whl.
File metadata
- Download URL: ollama_installer-0.1.0-py3-none-any.whl
- Upload date:
- Size: 7.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d2e852a5f68941051f7350eaf110efbb85601207325aac799695bfb53819b0ab
|
|
| MD5 |
2a6a22716b032baad06b8d6932e6b375
|
|
| BLAKE2b-256 |
58656ed8d51352f9f67fc528713dd57f85f004bd15074e8b53db9796480fa2d7
|