webifier


Namewebifier JSON
Version 0.1.20 PyPI version JSON
download
home_pagehttps://github.com/webifier/build
SummaryCook up a fully functional (semi-)static website to be served with jekyll!
upload_time2024-04-03 18:17:21
maintainerNone
docs_urlNone
authorVahid Zehtab, Ahmad Salimi
requires_pythonNone
licenseMIT
keywords webifier jupyter notebook markdown jekyll
VCS
bugtrack_url
requirements ipython_genutils nbconvert beautifulsoup4 pyyaml ipython Pygments Markdown jinja2
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Webifier

<p align="center">
  <a href="#how-to-use">How to Use</a> •
  <a href="https://webifier.github.io/">Docs</a> •
  <a href="#license">License</a>
</p>

<p align="center" markdown="1">
    <a href="https://github.com/webifier/build/actions/workflows/python-publish.yml" >
        <img src="https://github.com/webifier/build/actions/workflows/python-publish.yml/badge.svg" alt="Webify & Deploy">
    </a>
</p>

Webifier is a stand-alone build tool for converting any repository into a deployable [jekyll](https://jekyllrb.com/)
website. You can define your pages via `yaml` files and provide notebooks, markdown and pdf and other files for Webifier
to render. It uses [python markdown](https://python-markdown.github.io/)
providing additional control over attributes and other extensive functionalities. It lets you define and direct how your
web pages feel and automatically manages your assets, making it a perfect solution for fast static website development
and a straightforward tool for creating Github pages as a Github action. Webifier is a good fit for the missing puzzle
piece of collaborative content creation on Github and is a great tool for sharing educational material on the web.

Webifier lets you communicate with your audience through comments with the help of [utterances](https://utteranc.es/)
and track their engagement through [Google Analytics](https://analytics.google.com/). It also automatically creates a
static search engine with the help of [Jekyll-Simple-Search](https://github.com/christian-fei/Simple-Jekyll-Search). And 
as a cherry on the cake, you can provide custom [jinja2](https://jinja.palletsprojects.com/en/3.0.x/) templates if 
the built-in ones do not satisfy your needs. Plus, you can change the behavior of the rendering stage of Webifier by 
providing your custom implementation of  `assets`, `_includes`, and `_layouts` in your repository.

## How to Use

### Locally

In order to see how your webified pages look before you send it out to the world, you might want to build and serve them
locally. For this you would need both webifier and jekyll installed.

1. [Install Jekyll](https://jekyllrb.com/docs/installation/).
2. Install **webifier** from PYPI (webifier uses `python>=3.8` therefore you might need
   to [install an appropriate python version](https://www.python.org/downloads/) beforehand):
   ```shell
   pip install webifier
   ```
3. Change your working directory to where your website resides and Webify everything (assuming your initial index file
   is `index.yml`, and you want the results to go to `webified`)
   ```shell
   # cwd should be where your files are
   webify --index=index.yml --output=webified
   ```
4. Change your working directory to the webified results and serve jekyll:
   ```shell
    cd webified
    jekyll serve
    ```
   You can now access your website from `localhost:4000` by default.

### Github

Using Webifier for your repositories is as simple as adding it as a step in your deployment workflow. After checking out
your desired repository, add the Webifier action and change the default values for `baseurl`, `repo`, and `index` input
variables to your needs. After that you are good to deploy your Webified website for which there are a number of great
actions available.

Your workflow might look something like follows. We are using
[peaceiris/actions-gh-pages](https://github.com/peaceiris/actions-gh-pages) deploy action as an example here and you can
replace it with any other deployment action or even push the webified results into a separate github branch manually.
Keep in mind that because the results are pushed to a separate branch, you might need to change the Github Pages source
branch from your repository settings under the Pages section.

```yaml
name: Webify & Deploy
on:
  push:
    branches: [ master ]
jobs:
  build-and-deploy:
    runs-on: ubuntu-latest
    steps:
      # you need to checkout your code before webifying
      - name: Checkout
        uses: actions/checkout@v2
      - name: Webify
        uses: webifier/build@master # or select a desired version

      # the deploy action is in charge of pushing back the 
      #     webified files into a separate branch such as `gh-pages`
      - name: Deploy
        uses: peaceiris/actions-gh-pages@v3 # or use any other jekyll deploy action
        with:
          github_token: ${{ secrets.GITHUB_TOKEN }}
          enable_jekyll: true
          publish_dir: ./webified/
```

Note that if you wish to webify a `<name>.github.io` repository or do not wish to have the content of your repository to
be referred to with a `/<repository-name>/` slug, you should provide `baseurl: ''` to the webifier action. It is highly
suggested that you consult the [documentations](https://webifier.github.io/) for further details of the nuts and bolts
of webifiable materials. You can also look at the documentations'
[code](https://github.com/webifier/webifier.github.io) which itself is built using Webifier and greatly showcases its
functionalities.

## License

MIT License, see [webifier/build/LICENSE](https://github.com/webifier/build/blob/master/LICENSE).

## Todo

There are a number of improvements that can enlarge Webifier's usability. What follows is a list of the ideas that we
have in mind, feel free to suggest your ideas by opening up a feature request issue.

* **Print content**: add automatic print (and export as pdf) functionality for content content (markdown/notebook)
  pages.
* **Table of Content**: add automatic creation of a customizable multi-level table of content for all pages.





            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/webifier/build",
    "name": "webifier",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "webifier, jupyter notebook, markdown, jekyll",
    "author": "Vahid Zehtab, Ahmad Salimi",
    "author_email": "vahid98zee@gmail.com, ahsa9978@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/21/31/6a419c6276b619ee13f0a624904f872fb93063fe1a8073869d0dd5bf8423/webifier-0.1.20.tar.gz",
    "platform": null,
    "description": "# Webifier\n\n<p align=\"center\">\n  <a href=\"#how-to-use\">How to Use</a> \u2022\n  <a href=\"https://webifier.github.io/\">Docs</a> \u2022\n  <a href=\"#license\">License</a>\n</p>\n\n<p align=\"center\" markdown=\"1\">\n    <a href=\"https://github.com/webifier/build/actions/workflows/python-publish.yml\" >\n        <img src=\"https://github.com/webifier/build/actions/workflows/python-publish.yml/badge.svg\" alt=\"Webify & Deploy\">\n    </a>\n</p>\n\nWebifier is a stand-alone build tool for converting any repository into a deployable [jekyll](https://jekyllrb.com/)\nwebsite. You can define your pages via `yaml` files and provide notebooks, markdown and pdf and other files for Webifier\nto render. It uses [python markdown](https://python-markdown.github.io/)\nproviding additional control over attributes and other extensive functionalities. It lets you define and direct how your\nweb pages feel and automatically manages your assets, making it a perfect solution for fast static website development\nand a straightforward tool for creating Github pages as a Github action. Webifier is a good fit for the missing puzzle\npiece of collaborative content creation on Github and is a great tool for sharing educational material on the web.\n\nWebifier lets you communicate with your audience through comments with the help of [utterances](https://utteranc.es/)\nand track their engagement through [Google Analytics](https://analytics.google.com/). It also automatically creates a\nstatic search engine with the help of [Jekyll-Simple-Search](https://github.com/christian-fei/Simple-Jekyll-Search). And \nas a cherry on the cake, you can provide custom [jinja2](https://jinja.palletsprojects.com/en/3.0.x/) templates if \nthe built-in ones do not satisfy your needs. Plus, you can change the behavior of the rendering stage of Webifier by \nproviding your custom implementation of  `assets`, `_includes`, and `_layouts` in your repository.\n\n## How to Use\n\n### Locally\n\nIn order to see how your webified pages look before you send it out to the world, you might want to build and serve them\nlocally. For this you would need both webifier and jekyll installed.\n\n1. [Install Jekyll](https://jekyllrb.com/docs/installation/).\n2. Install **webifier** from PYPI (webifier uses `python>=3.8` therefore you might need\n   to [install an appropriate python version](https://www.python.org/downloads/) beforehand):\n   ```shell\n   pip install webifier\n   ```\n3. Change your working directory to where your website resides and Webify everything (assuming your initial index file\n   is `index.yml`, and you want the results to go to `webified`)\n   ```shell\n   # cwd should be where your files are\n   webify --index=index.yml --output=webified\n   ```\n4. Change your working directory to the webified results and serve jekyll:\n   ```shell\n    cd webified\n    jekyll serve\n    ```\n   You can now access your website from `localhost:4000` by default.\n\n### Github\n\nUsing Webifier for your repositories is as simple as adding it as a step in your deployment workflow. After checking out\nyour desired repository, add the Webifier action and change the default values for `baseurl`, `repo`, and `index` input\nvariables to your needs. After that you are good to deploy your Webified website for which there are a number of great\nactions available.\n\nYour workflow might look something like follows. We are using\n[peaceiris/actions-gh-pages](https://github.com/peaceiris/actions-gh-pages) deploy action as an example here and you can\nreplace it with any other deployment action or even push the webified results into a separate github branch manually.\nKeep in mind that because the results are pushed to a separate branch, you might need to change the Github Pages source\nbranch from your repository settings under the Pages section.\n\n```yaml\nname: Webify & Deploy\non:\n  push:\n    branches: [ master ]\njobs:\n  build-and-deploy:\n    runs-on: ubuntu-latest\n    steps:\n      # you need to checkout your code before webifying\n      - name: Checkout\n        uses: actions/checkout@v2\n      - name: Webify\n        uses: webifier/build@master # or select a desired version\n\n      # the deploy action is in charge of pushing back the \n      #     webified files into a separate branch such as `gh-pages`\n      - name: Deploy\n        uses: peaceiris/actions-gh-pages@v3 # or use any other jekyll deploy action\n        with:\n          github_token: ${{ secrets.GITHUB_TOKEN }}\n          enable_jekyll: true\n          publish_dir: ./webified/\n```\n\nNote that if you wish to webify a `<name>.github.io` repository or do not wish to have the content of your repository to\nbe referred to with a `/<repository-name>/` slug, you should provide `baseurl: ''` to the webifier action. It is highly\nsuggested that you consult the [documentations](https://webifier.github.io/) for further details of the nuts and bolts\nof webifiable materials. You can also look at the documentations'\n[code](https://github.com/webifier/webifier.github.io) which itself is built using Webifier and greatly showcases its\nfunctionalities.\n\n## License\n\nMIT License, see [webifier/build/LICENSE](https://github.com/webifier/build/blob/master/LICENSE).\n\n## Todo\n\nThere are a number of improvements that can enlarge Webifier's usability. What follows is a list of the ideas that we\nhave in mind, feel free to suggest your ideas by opening up a feature request issue.\n\n* **Print content**: add automatic print (and export as pdf) functionality for content content (markdown/notebook)\n  pages.\n* **Table of Content**: add automatic creation of a customizable multi-level table of content for all pages.\n\n\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Cook up a fully functional (semi-)static website to be served with jekyll!",
    "version": "0.1.20",
    "project_urls": {
        "Homepage": "https://github.com/webifier/build"
    },
    "split_keywords": [
        "webifier",
        " jupyter notebook",
        " markdown",
        " jekyll"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d569294616d93e02a77afb0cafcf8df0b9fb11b01d6b257f225e07a0a6093e35",
                "md5": "5b4479f6c255c868a4ace50311e0893d",
                "sha256": "111b32322479b18259bc5c4a766839af374f0c376870c72885f0803082a1467e"
            },
            "downloads": -1,
            "filename": "webifier-0.1.20-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5b4479f6c255c868a4ace50311e0893d",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 76763,
            "upload_time": "2024-04-03T18:17:20",
            "upload_time_iso_8601": "2024-04-03T18:17:20.405019Z",
            "url": "https://files.pythonhosted.org/packages/d5/69/294616d93e02a77afb0cafcf8df0b9fb11b01d6b257f225e07a0a6093e35/webifier-0.1.20-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "21316a419c6276b619ee13f0a624904f872fb93063fe1a8073869d0dd5bf8423",
                "md5": "5d3bcbf12b9052e64066d79a73fd6ba4",
                "sha256": "f7691bfcaf6763fb00513eaf75ab90f35f0b5c69978281690eb7a9b43f33077a"
            },
            "downloads": -1,
            "filename": "webifier-0.1.20.tar.gz",
            "has_sig": false,
            "md5_digest": "5d3bcbf12b9052e64066d79a73fd6ba4",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 70995,
            "upload_time": "2024-04-03T18:17:21",
            "upload_time_iso_8601": "2024-04-03T18:17:21.724480Z",
            "url": "https://files.pythonhosted.org/packages/21/31/6a419c6276b619ee13f0a624904f872fb93063fe1a8073869d0dd5bf8423/webifier-0.1.20.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-03 18:17:21",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "webifier",
    "github_project": "build",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [
        {
            "name": "ipython_genutils",
            "specs": []
        },
        {
            "name": "nbconvert",
            "specs": [
                [
                    "==",
                    "5.6.1"
                ]
            ]
        },
        {
            "name": "beautifulsoup4",
            "specs": []
        },
        {
            "name": "pyyaml",
            "specs": []
        },
        {
            "name": "ipython",
            "specs": []
        },
        {
            "name": "Pygments",
            "specs": []
        },
        {
            "name": "Markdown",
            "specs": []
        },
        {
            "name": "jinja2",
            "specs": [
                [
                    "==",
                    "3.0.3"
                ]
            ]
        }
    ],
    "lcname": "webifier"
}
        
Elapsed time: 4.48383s