Compare commits
	
		
			3 Commits
		
	
	
		
			cf8eaaaf83
			...
			main
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					6a0424a3e1 | ||
| 
						 | 
					d513f6c565 | ||
| 
						 | 
					67540962cf | 
@ -1,4 +1,3 @@
 | 
			
		||||
```
 | 
			
		||||
# lazy_serve
 | 
			
		||||
 | 
			
		||||
A simple, easy-to-use Python package for starting HTTP servers with minimal setup. Ideal for serving static files in development environments or for lightweight file sharing.
 | 
			
		||||
@ -7,10 +6,11 @@ A simple, easy-to-use Python package for starting HTTP servers with minimal setu
 | 
			
		||||
 | 
			
		||||
To install lazy_serve, simply use pip:
 | 
			
		||||
 | 
			
		||||
```sh
 | 
			
		||||
```bash
 | 
			
		||||
pip install lazy_serve
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## Usage
 | 
			
		||||
 | 
			
		||||
Using lazy_serve is straightforward. Here's a basic example:
 | 
			
		||||
 | 
			
		||||
@ -2,6 +2,7 @@ import os
 | 
			
		||||
import signal
 | 
			
		||||
import subprocess
 | 
			
		||||
import threading
 | 
			
		||||
import time
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class ServerThread(threading.Thread):
 | 
			
		||||
@ -22,6 +23,8 @@ class ServerThread(threading.Thread):
 | 
			
		||||
            self.process.poll()
 | 
			
		||||
            if self.process.returncode is not None:
 | 
			
		||||
                break
 | 
			
		||||
            else:
 | 
			
		||||
                time.sleep(0.2)
 | 
			
		||||
 | 
			
		||||
    def stop(self):
 | 
			
		||||
        self._stop_event.set()
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										8
									
								
								makefile
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								makefile
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,8 @@
 | 
			
		||||
clean:
 | 
			
		||||
	rm -rf dist/
 | 
			
		||||
 | 
			
		||||
build: clean
 | 
			
		||||
	python -m build --sdist --wheel
 | 
			
		||||
 | 
			
		||||
pub: build
 | 
			
		||||
	twine upload dist/*
 | 
			
		||||
							
								
								
									
										10
									
								
								setup.py
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								setup.py
									
									
									
									
									
								
							@ -2,13 +2,13 @@ from setuptools import find_packages, setup
 | 
			
		||||
 | 
			
		||||
setup(
 | 
			
		||||
    name="lazy_serve",
 | 
			
		||||
    version="0.2",
 | 
			
		||||
    description="A simple package for effortlessly starting HTTP servers.",
 | 
			
		||||
    version="0.2.1",
 | 
			
		||||
    description="A simple package for effortlessly starting multiple threaded HTTP servers.",
 | 
			
		||||
    long_description=open("README.md").read(),
 | 
			
		||||
    long_description_content_type="text/markdown",
 | 
			
		||||
    author="Your Name",
 | 
			
		||||
    author_email="your.email@example.com",
 | 
			
		||||
    url="https://github.com/yourusername/lazy_serve",
 | 
			
		||||
    author="Michael Pilosov",
 | 
			
		||||
    author_email="mm@clfx.cc",
 | 
			
		||||
    url="https://git.mlden.com/mm/lazy_serve.git",
 | 
			
		||||
    packages=find_packages(),
 | 
			
		||||
    install_requires=[],
 | 
			
		||||
    python_requires=">=3.6",
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user