ssb-pubmd 0.1.11
SSB Pubmd
License: MIT
Requires Python: <4.0,>=3.10

# SSB Pubmd

[![PyPI](https://img.shields.io/pypi/v/ssb-pubmd.svg)][pypi status]
[![Status](https://img.shields.io/pypi/status/ssb-pubmd.svg)][pypi status]
[![Python Version](https://img.shields.io/pypi/pyversions/ssb-pubmd)][pypi status]
[![License](https://img.shields.io/pypi/l/ssb-pubmd)][license]

[![Documentation](https://github.com/statisticsnorway/ssb-pubmd/actions/workflows/docs.yml/badge.svg)][documentation]
[![Tests](https://github.com/statisticsnorway/ssb-pubmd/actions/workflows/tests.yml/badge.svg)][tests]
[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=statisticsnorway_ssb-pubmd&metric=coverage)][sonarcov]
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=statisticsnorway_ssb-pubmd&metric=alert_status)][sonarquality]

[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)][pre-commit]
[![Black](https://img.shields.io/badge/code%20style-black-000000.svg)][black]
[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
[![Poetry](https://img.shields.io/endpoint?url=https://python-poetry.org/badge/v0.json)][poetry]

[pypi status]: https://pypi.org/project/ssb-pubmd/
[documentation]: https://statisticsnorway.github.io/ssb-pubmd
[tests]: https://github.com/statisticsnorway/ssb-pubmd/actions?workflow=Tests
[sonarcov]: https://sonarcloud.io/summary/overall?id=statisticsnorway_ssb-pubmd
[sonarquality]: https://sonarcloud.io/summary/overall?id=statisticsnorway_ssb-pubmd
[pre-commit]: https://github.com/pre-commit/pre-commit
[black]: https://github.com/psf/black
[poetry]: https://python-poetry.org/

## Features

- TODO

## Requirements

- TODO

## Installation

You can install _SSB Pubmd_ via [pip] from [PyPI]:

```console
pip install ssb-pubmd
```

## Usage

Please see the [Reference Guide] for details.

## Development

### Testing latest development version

1. Open a Jupyter service in [Dapla Dev](https://lab.dapla-dev.ssb.no/)
2. Open a Jupyter terminal and run the following commands:

```
ssb-project create my-project
cd my-project
poetry source add testpypi https://test.pypi.org/simple/ -p explicit
poetry add "pandas<3"
poetry add ssb-pubmd@latest --source testpypi --allow-prereleases
poetry run ssb-pubmd create my-article
```

3. Follow the instructions from the last command.
4. After pushing new changes (to any branch), update the package with:

```
poetry update ssb-pubmd
```

### Architecture

```mermaid
graph LR
     subgraph driving[Interface]
          cli[run_cli]
          template[create_template_article]
          article[get_article_preview]
          component[create_component]
     end
     subgraph core[Core]
          docpublisher[DocumentPublisher]
     end
     subgraph driven[Adapters]
          docprocessor[DocumentProcessor]
          cmsclient[CmsClient]
          storage[Storage]
     end
     cmsservice[Cms Service]

     cli --> template
     cli --> article --> docpublisher

     docpublisher --- split[ ]:::empty
     split --> docprocessor
     split --> cmsclient
     split --> storage

     cmsclient --> cmsservice

     component --> storage

     classDef empty width:0px,height:0px;
```

## License

Distributed under the terms of the [MIT license][license],
_SSB Pubmd_ is free and open source software.

## Issues

If you encounter any problems,
please [file an issue] along with a detailed description.

## Credits

This project was generated from [Statistics Norway]'s [SSB PyPI Template].

[statistics norway]: https://www.ssb.no/en
[pypi]: https://pypi.org/
[ssb pypi template]: https://github.com/statisticsnorway/ssb-pypitemplate
[file an issue]: https://github.com/statisticsnorway/ssb-pubmd/issues
[pip]: https://pip.pypa.io/

<!-- github-only -->

[license]: https://github.com/statisticsnorway/ssb-pubmd/blob/main/LICENSE
[contributor guide]: https://github.com/statisticsnorway/ssb-pubmd/blob/main/CONTRIBUTING.md
[reference guide]: https://statisticsnorway.github.io/ssb-pubmd/reference.html