hyde-gopher


Namehyde-gopher JSON
Version 0.4.0 PyPI version JSON
download
home_pagehttps://github.com/YtvwlD/hyde-gopher
Summarya gopher server for Hyde sites
upload_time2023-01-14 21:30:12
maintainer
docs_urlNone
authorNiklas Sombert
requires_python~=3.6
licenseGPLv3
keywords hyde gopher
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage No coveralls.
            # hyde-gopher

[![Build Status](https://travis-ci.org/YtvwlD/hyde-gopher.svg?branch=main)](https://travis-ci.org/YtvwlD/hyde-gopher)

Serve your [Hyde](https://hyde.github.io/) site over
[Gopher](https://en.wikipedia.org/wiki/Gopher_(protocol)).
(This is primarily made possible by [flask-gopher](https://github.com/michael-lazar/flask-gopher), yay.)

## Installation

pandoc is needed to parse Markdown, so you'll need to have this installed.

### Release

You can install the latest relase from PyPI by running

```shell
python3 -m pip install hyde-gopher
```

### From source

If you want to use the latest development snapshot (which may be broken),
you'll need to clone or download the repository and then install the package with:

```shell
python3 -m pip install .
```

If you don't want to install anything, you can replace `hyde-gopher` with
`python3 -m hyde_gopher.main` in the following steps.

## Usage

### Setup

As Gopher supports only absolute links and there's no such thing as a `Host` header,
hyde-gopher needs to know the absolute base path of your site when generating the
static site. (If you're using the built-in webserver this is currently being guessed
from the bind configuration which may lead to broken links. Please use the built-in
webserver just for local tests and not for internet-facing deployments.)

There are also a few things you might want to configure but don't have to.

To do so, add the following lines to your `site.yaml`:

```yaml
gopher_base_url: gopher://gopher.mysite.invalid:71/~user/ # needed
gopher_layout_root: layout_gopher # this is the default
gopher_width: 70 # this is the default
```

If you don't want to create your layout from scratch you can use a bundled one
 – to do so, run `hyde-gopher init`.

### Serve

You can use the built-in webserver for a quick test
 – and also for pre-viewing your site while editing it.

To do so, run `hyde-gopher serve`.

Per default, this will serve the site from the current working directory
at <gopher://localhost:7070/>, placing generated files into `deploy_gopher/`.
(You can change this, see `hyde-gopher -h` and `hyde-gopher serve -h` for more options.)

### Generate

The primary purpose of hyde-gopher is to generate a static site (just like hyde's).

To do so, run `hyde-gopher gen`.

Per default, this will generate a static version of the site from the current
working directory to the folder `deploy_gopher/`.
(You can change this, see `hyde-gopher -h` and `hyde-gopher gen -h` for more options.)

## Knonwn issues / TODO

 * links in HTML pages are not rendered as links (it works in Markdown, though)
 * images are only linked if you use a macro to render them
 * just HTML files, binaries and folders are considered

## Gotchas

hyde-gopher needs Python >= 3.6.

The currenty stable release of hyde (0.8.9) needs Python < 3.
You'll need to install the pre-release of hyde 0.9.0 to get this working:

```shell
python3 -m pip install git+https://github.com/hyde/hyde.git@V0.9.0
```



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/YtvwlD/hyde-gopher",
    "name": "hyde-gopher",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "~=3.6",
    "maintainer_email": "",
    "keywords": "hyde,gopher",
    "author": "Niklas Sombert",
    "author_email": "niklas@ytvwld.de",
    "download_url": "",
    "platform": null,
    "description": "# hyde-gopher\n\n[![Build Status](https://travis-ci.org/YtvwlD/hyde-gopher.svg?branch=main)](https://travis-ci.org/YtvwlD/hyde-gopher)\n\nServe your [Hyde](https://hyde.github.io/) site over\n[Gopher](https://en.wikipedia.org/wiki/Gopher_(protocol)).\n(This is primarily made possible by [flask-gopher](https://github.com/michael-lazar/flask-gopher), yay.)\n\n## Installation\n\npandoc is needed to parse Markdown, so you'll need to have this installed.\n\n### Release\n\nYou can install the latest relase from PyPI by running\n\n```shell\npython3 -m pip install hyde-gopher\n```\n\n### From source\n\nIf you want to use the latest development snapshot (which may be broken),\nyou'll need to clone or download the repository and then install the package with:\n\n```shell\npython3 -m pip install .\n```\n\nIf you don't want to install anything, you can replace `hyde-gopher` with\n`python3 -m hyde_gopher.main` in the following steps.\n\n## Usage\n\n### Setup\n\nAs Gopher supports only absolute links and there's no such thing as a `Host` header,\nhyde-gopher needs to know the absolute base path of your site when generating the\nstatic site. (If you're using the built-in webserver this is currently being guessed\nfrom the bind configuration which may lead to broken links. Please use the built-in\nwebserver just for local tests and not for internet-facing deployments.)\n\nThere are also a few things you might want to configure but don't have to.\n\nTo do so, add the following lines to your `site.yaml`:\n\n```yaml\ngopher_base_url: gopher://gopher.mysite.invalid:71/~user/ # needed\ngopher_layout_root: layout_gopher # this is the default\ngopher_width: 70 # this is the default\n```\n\nIf you don't want to create your layout from scratch you can use a bundled one\n \u2013 to do so, run `hyde-gopher init`.\n\n### Serve\n\nYou can use the built-in webserver for a quick test\n \u2013 and also for pre-viewing your site while editing it.\n\nTo do so, run `hyde-gopher serve`.\n\nPer default, this will serve the site from the current working directory\nat <gopher://localhost:7070/>, placing generated files into `deploy_gopher/`.\n(You can change this, see `hyde-gopher -h` and `hyde-gopher serve -h` for more options.)\n\n### Generate\n\nThe primary purpose of hyde-gopher is to generate a static site (just like hyde's).\n\nTo do so, run `hyde-gopher gen`.\n\nPer default, this will generate a static version of the site from the current\nworking directory to the folder `deploy_gopher/`.\n(You can change this, see `hyde-gopher -h` and `hyde-gopher gen -h` for more options.)\n\n## Knonwn issues / TODO\n\n * links in HTML pages are not rendered as links (it works in Markdown, though)\n * images are only linked if you use a macro to render them\n * just HTML files, binaries and folders are considered\n\n## Gotchas\n\nhyde-gopher needs Python >= 3.6.\n\nThe currenty stable release of hyde (0.8.9) needs Python < 3.\nYou'll need to install the pre-release of hyde 0.9.0 to get this working:\n\n```shell\npython3 -m pip install git+https://github.com/hyde/hyde.git@V0.9.0\n```\n\n\n",
    "bugtrack_url": null,
    "license": "GPLv3",
    "summary": "a gopher server for Hyde sites",
    "version": "0.4.0",
    "split_keywords": [
        "hyde",
        "gopher"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "622091ca188473cc7b43ed9278adb93439eb038e36f13d376708de01ac084d84",
                "md5": "31e7db8d7cc4e88a226ea4a9f7f5ab85",
                "sha256": "ee77bf5e606c5eaab80255c185a1c0174acb207372350001f6fa05aaa7c8ec6d"
            },
            "downloads": -1,
            "filename": "hyde_gopher-0.4.0-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "31e7db8d7cc4e88a226ea4a9f7f5ab85",
            "packagetype": "bdist_wheel",
            "python_version": "py2.py3",
            "requires_python": "~=3.6",
            "size": 23186,
            "upload_time": "2023-01-14T21:30:12",
            "upload_time_iso_8601": "2023-01-14T21:30:12.147672Z",
            "url": "https://files.pythonhosted.org/packages/62/20/91ca188473cc7b43ed9278adb93439eb038e36f13d376708de01ac084d84/hyde_gopher-0.4.0-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-01-14 21:30:12",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "YtvwlD",
    "github_project": "hyde-gopher",
    "travis_ci": true,
    "coveralls": false,
    "github_actions": false,
    "lcname": "hyde-gopher"
}
        
Elapsed time: 0.04203s