ADO2Hugo
With this program you will be able to export Azure DevOps wikis to Hugo
Azure DevOps offers two kinds of wiki: Project (managed by the platform) or "Wiki as code" (publish directly markdown files from a branch in your repository).
Currently, only wiki projects are supported, and it does not have sense to support the "wiki as code" option.
The program uses the Azure DevOps API to iterate over an organization's projects and, in accordance with Hugo's folder structure, exports all wiki pages with their corresponding attachments.
I have used Geekdoc theme.
Installation
pip install ado2hugo
Usage
ado2hugo -h
usage: ado2hugo [-h] [--organization ORGANIZATION] [--pat PAT] [--project PROJECT] [-v] site_dir
positional arguments:
site_dir Site directory
optional arguments:
-h, --help show this help message and exit
--organization ORGANIZATION
Organization
--pat PAT Personal access token
--project PROJECT Project name
-v, --verbose Verbose
ORGANIZATION and PAT options, can be also an environment variable.
ado2hugo --organization <YOUR_ORGANIZATION> --pat <YOUR_PAT> <YOUR_SITE_DIRECTORY>
Be carefully because this program deletes before its execution, all files in the /static and /content folders of supplied path
Development
You must run the following commands to develop localy:
- Create a pipenv local environment with
pipenv install --dev - Install pre-commit hooks with
pre-commit install
For executing __main__.py, you must use python -m src.ado2hugo, so relative imports will work, if you use python __main__.py you will receive the error ImportError: attempted relative import with no known parent package,
more information in https://napuzba.com/a/import-error-relative-no-parent
Metadata
Release files for ado2hugo 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ado2hugo-1.0.2-py3-none-any.whl | Python 3 | none | any | Details for ado2hugo-1.0.2-py3-none-any.whl |
Release files / ado2hugo-1.0.2-py3-none-any.whl
| Download URL | ado2hugo-1.0.2-py3-none-any.whl |
|---|---|
| Size | 8.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6ecbee7bfcddce39fbf3cbf499e9a7cbc0644a37dd96723ec255ccb24798ac8e
|
|
BLAKE2b-256 checksum How to use checksums |
2bd558da3fbe5b12b3554ae68d3a1efd13a993c45cc064ad2001227baa05ec2b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
|
Security for ado2hugo 1.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.