Skip to main content

Website for course materials

Project description

naucse

This is a server for open course material.

To use it, you will need some content. Usually, the repository with the content will require the naucse module, and will run using python -m naucse.

We use content at https://github.com/pyvec/naucse.python.cz to generate naucse.python.cz.

Installation

Install from a virtual environment.

To install the latest release:

(venv)$ python -m pip install naucse

To install from a cloned repository, for development:

(venv)$ python -m pip install -e.[dev]

Running

To run the serve, either change (cd) to the directory with content, or set NAUCSE_ROOT_PATH to that directory. Then run:

(venv)$ python -m naucse serve

Instead of serve, you can run freeze to generate a static website. See Elsa for other usage, including deployment to GitHub Pages.

Served courses

The courses on the served website are taken from two sources:

  • courses.yml in $NAUCSE_ROOT_PATH, with entries like:

      course_slug:
          url: https://github.com/user/repo
          branch: main
          path: _compiled
    

    The named repositories will be cloned. At the given path in the given branch, naucse expects compiled course info, as prepared by python -m naucse_render compile.

    This is intended for the production site, which aggregates lots of individual courses.

  • Any courses found by python -m naucse_render ls. This is useful when developing a course locally.

Tests

Tests can be run using tox:

(venv)$ tox

or pytest directly:

(venv)$ python -m pytest

Licence

The code is licensed under the terms of the MIT license, see LICENSE.MIT file for full text. By contributing code to this repository, you agree to have it licensed under the same license.

Content has its own license specified in the appropriate matadata. Only free content licenses are used. By contributing to an already licensed document, you agree to have it licensed under the same license. (And feel free to add yourself to the authors list in its metadata.) When contributing new document(s) a license must be specified in the metadata.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

naucse-0.5.0-py3-none-any.whl (783.5 kB view details)

Uploaded Python 3

File details

Details for the file naucse-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: naucse-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 783.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.27.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.10.2

File hashes

Hashes for naucse-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9fc42a841af53cc63d304456ce0872ed8dbcd222961d2bead2907cbcb827067d
MD5 cb94732ca8ed763f82761666ac309ae1
BLAKE2b-256 f9baf152291de31bc9e6d4cc875c37abd6e376cd8003469a20a6235eb32afef7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page