add setup.py
This commit is contained in:
parent
174e157ab8
commit
b798858d94
3 changed files with 64 additions and 5 deletions
4
jekyll-to-hugo
Normal file
4
jekyll-to-hugo
Normal file
|
@ -0,0 +1,4 @@
|
|||
from main import main
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
37
readme.md
37
readme.md
|
@ -2,15 +2,33 @@
|
|||
|
||||
Jekyll to Hugo Converter is a simple tool to convert Jekyll posts to Hugo posts.
|
||||
|
||||
You can also use it to convert your WordPress blog into a Hugo blog. Tutorial coming soon.
|
||||
I've used this tool to convert [my blog](https://blog.nuculabs.dev) from WorPress to Jekyll to Hugo.
|
||||
|
||||
Note:
|
||||
- This tool is still under development.
|
||||
- This tool is not perfect, it will not convert everything. If you find a bug, please open a PR.
|
||||
Note: This tool is not perfect, it will not convert everything. If you find a bug, please open a PR.
|
||||
|
||||
## Table of Contents
|
||||
|
||||
* [Usage](#usage)
|
||||
* [PiPy](#pipy)
|
||||
* [Python From Source](#python-from-source)
|
||||
* [Docker](#docker)
|
||||
* [Configuration](#configuration)
|
||||
* [License](#license)
|
||||
|
||||
## Usage
|
||||
|
||||
### Python
|
||||
### PiPy
|
||||
|
||||
If you have Python installed, you can use the following commands:
|
||||
|
||||
```bash
|
||||
pip install jekyll-to-hugo
|
||||
jekyll-to-hugo
|
||||
```
|
||||
|
||||
You will need to create a `config.yaml` file in the current directory. See example [here](./config.yaml).
|
||||
|
||||
### Python From Source
|
||||
|
||||
If you have Python installed, you can use the following commands:
|
||||
|
||||
|
@ -39,5 +57,14 @@ docker build -t jekyll-to-hugo .
|
|||
docker run -it --rm -v $(pwd):/app jekyll-to-hugo
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
The configuration file is a YAML file. See example [here](./config.yaml).
|
||||
The configuration file path can be configured with the `CONFIG_PATH` environment variable.
|
||||
|
||||
## License
|
||||
|
||||
This project is licensed under the GPL-3.0 license - see the [LICENSE](LICENSE) file for details.
|
||||
|
||||
---
|
||||
Made with ❤️ by [NucuLabs.dev](https://blog.nuculabs.dev)
|
28
setup.py
Normal file
28
setup.py
Normal file
|
@ -0,0 +1,28 @@
|
|||
import setuptools
|
||||
|
||||
with open("readme.md", "r") as fh:
|
||||
long_description = fh.read()
|
||||
|
||||
setuptools.setup(
|
||||
name="jekyll-to-hugo",
|
||||
version="0.0.1",
|
||||
author="Denis Nutiu",
|
||||
author_email="nuculabs@outlook.com",
|
||||
description="Python library for converting jekyll md files to Hugo.",
|
||||
long_description=long_description,
|
||||
long_description_content_type="text/markdown",
|
||||
url="nuculabs.dev",
|
||||
packages=setuptools.find_packages(),
|
||||
classifiers=[
|
||||
"Programming Language :: Python :: 3",
|
||||
"Operating System :: OS Independent",
|
||||
],
|
||||
scripts=["jekyll-to-hugo"],
|
||||
install_requires=[
|
||||
"beautifulsoup4==4.12.2",
|
||||
"PyYAML==6.0",
|
||||
"soupsieve==2.4.1",
|
||||
"pydantic==1.10.8",
|
||||
],
|
||||
python_requires=">=3.10",
|
||||
)
|
Loading…
Reference in a new issue