mirror of
https://github.com/kirill-markin/repo-to-text.git
synced 2025-12-05 19:12:24 -08:00
Added localized dockerized build instructions with documentation
This commit is contained in:
parent
07521f06ca
commit
2759fd3640
3 changed files with 50 additions and 0 deletions
27
DOCKER.md
Normal file
27
DOCKER.md
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
# Docker Usage Instructions
|
||||
|
||||
## Building and Running
|
||||
|
||||
1. Build the container:
|
||||
```bash
|
||||
docker-compose build
|
||||
```
|
||||
|
||||
2. Start a shell session:
|
||||
```bash
|
||||
docker-compose run --rm repo-to-text
|
||||
```
|
||||
|
||||
Once in the shell, you can run repo-to-text:
|
||||
```bash
|
||||
# Process current directory
|
||||
repo-to-text
|
||||
|
||||
# Process specific directory
|
||||
repo-to-text /home/user/myproject
|
||||
|
||||
# Use with options
|
||||
repo-to-text --output-dir /home/user/output
|
||||
```
|
||||
|
||||
The container mounts your home directory at `/home/user`, allowing access to all your projects.
|
||||
13
Dockerfile
Normal file
13
Dockerfile
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
FROM python:3.11-slim
|
||||
|
||||
RUN apt-get update && apt-get install -y \
|
||||
tree \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN useradd -m -s /bin/bash user
|
||||
|
||||
WORKDIR /app
|
||||
COPY . .
|
||||
RUN pip install -e . && pip install pyperclip
|
||||
|
||||
ENTRYPOINT ["repo-to-text"]
|
||||
10
docker-compose.yaml
Normal file
10
docker-compose.yaml
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
services:
|
||||
repo-to-text:
|
||||
build: .
|
||||
volumes:
|
||||
- ${HOME:-/home/user}:/home/user
|
||||
working_dir: /home/user
|
||||
environment:
|
||||
- HOME=/home/user
|
||||
user: "${UID:-1000}:${GID:-1000}"
|
||||
entrypoint: ["/bin/bash"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue