Skip to content

Commit 8e69c58

Browse files
linawolfjaapio
authored andcommitted
[FEATURE] Create a rst theme to convert markdown
Convert basic mark-down into restructured Text * headlines * paragpraphs * links * lists * emphasis * inline-code
1 parent 9dce0df commit 8e69c58

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+905
-4
lines changed

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@
4343
"phpdocumentor/guides-graphs": "^2.0@dev || ^1.0",
4444
"phpdocumentor/guides-markdown": "^2.0@dev || ^1.0",
4545
"phpdocumentor/guides-restructured-text": "^2.0@dev || ^1.0",
46-
"phpdocumentor/guides-theme-bootstrap": "^2.0@dev || ^1.0"
46+
"phpdocumentor/guides-theme-bootstrap": "^2.0@dev || ^1.0",
47+
"phpdocumentor/guides-theme-rst": "^2.0@dev || ^1.0"
4748
},
4849
"require-dev": {
4950
"ext-dom": "*",

composer.lock

Lines changed: 42 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

config.subsplit-publish.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,11 @@
3434
"name": "guides-code",
3535
"directory": "packages/guides-code",
3636
"target": "git@github.com:phpDocumentor/guides-code.git"
37+
},
38+
{
39+
"name": "guides-theme-rst",
40+
"directory": "packages/guides-rst-theme",
41+
"target": "git@github.com:phpDocumentor/guides-theme-rst.git"
3742
}
3843
]
3944
}

deptrac.packages.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ deptrac:
4040
CLI:
4141
- "Guides"
4242
- "RST"
43+
- "Markdown"
4344
RST:
4445
- "Guides"
4546
Markdown:
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
/.gitattributes export-ignore
2+
/.gitignore export-ignore
3+
/docs export-ignore
4+
/tests export-ignore

packages/guides-theme-rst/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
vendor/*
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
======================================
2+
Contribute to the phpDocumentor Guides
3+
======================================
4+
5+
Go to the mono-repository
6+
=========================
7+
8+
This project is developed in the mono-repository `phpDocumentor Guides <https://github.com/phpDocumentor/guides>`__.
9+
The repository you are currently in gets auto-created by splitting the mono-repository. You **must not** contribute
10+
to this repository directly but always to the mono-repository linked above.
11+
12+
Create Issues
13+
=============
14+
15+
* If you find something missing or something is wrong in this library, you are welcome to write an issue
16+
describing the problem: `Issues on GitHub <https://github.com/phpDocumentor/guides/issues>`__.
17+
* If you can, please try to fix the problem yourself.
18+
19+
Make changes (create pull requests)
20+
===================================
21+
22+
See the `Contribution chapter <https://github.com/phpDocumentor/guides/tree/main/docs/contributions/index.rst>`__ in the
23+
`Documentation` <https://github.com/phpDocumentor/guides/tree/main/docs/index.rst>`__.

packages/guides-theme-rst/LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2010 Mike van Riel
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in
13+
all copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21+
THE SOFTWARE.

packages/guides-theme-rst/README.rst

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
2+
.. image:: http://poser.pugx.org/phpdocumentor/guides-restructured-text/require/php
3+
:alt: PHP Version Require
4+
:target: https://packagist.org/packages/phpdocumentor/guides-restructured-text
5+
6+
.. image:: http://poser.pugx.org/phpdocumentor/guides-restructured-text/v/stable
7+
:alt: Latest Stable Version
8+
:target: https://packagist.org/packages/phpdocumentor/guides-restructured-text
9+
10+
.. image:: http://poser.pugx.org/phpdocumentor/guides-restructured-text/v/unstable
11+
:alt: Latest Unstable Version
12+
:target: https://packagist.org/packages/phpdocumentor/guides-restructured-text
13+
14+
.. image:: https://poser.pugx.org/phpdocumentor/guides-restructured-text/d/total
15+
:alt: Total Downloads
16+
:target: https://packagist.org/packages/phpdocumentor/guides-restructured-text
17+
18+
.. image:: https://poser.pugx.org/phpdocumentor/guides-restructured-text/d/monthly
19+
:alt: Monthly Downloads
20+
:target: https://packagist.org/packages/phpdocumentor/guides-restructured-text
21+
22+
====================
23+
phpDocumentor Guides
24+
====================
25+
26+
This repository is part of `phpDocumentor's Guides library <https://github.com/phpDocumentor/guides>`__, a framework
27+
designed to take hand-written documentation in code repositories and create an AST (abstract syntax tree) from it.
28+
This AST is then fed to a renderer, which produces the desired output, such as HTML.
29+
30+
The package `phpdocumentor/guides-restructured-text <https://packagist.org/packages/phpdocumentor/guides-restructured-text>`__ adds
31+
`reStructuredText Markup <https://docutils.sourceforge.io/docs/ref/rst/restructuredtext.html>`__ support to the
32+
phpDocumentor's Guides library.
33+
34+
:Mono-Repository: https://github.com/phpDocumentor/guides
35+
:Documentation: https://github.com/phpDocumentor/guides/tree/main/docs/index.rst
36+
:Packagist: https://packagist.org/packages/phpdocumentor/guides-restructured-text
37+
:Contribution: https://github.com/phpDocumentor/guides/tree/main/CONTRIBUTING.rst
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"name": "phpdocumentor/guides-theme-rst",
3+
"description": "Adds a reStructuredText theme used to convert Markdown into reStructuredText",
4+
"type": "library",
5+
"license": "MIT",
6+
"homepage": "https://www.phpdoc.org",
7+
"config": {
8+
"sort-packages": true
9+
},
10+
"autoload": {
11+
"psr-4": {
12+
"phpDocumentor\\Guides\\": "src/"
13+
}
14+
},
15+
"autoload-dev": {
16+
"psr-4": {
17+
"phpDocumentor\\Guides\\": [
18+
"tests/unit/"
19+
]
20+
}
21+
},
22+
"minimum-stability": "stable",
23+
"require": {
24+
"php": "^8.1",
25+
"phpdocumentor/guides": "^1.0 || ^2.0"
26+
},
27+
"extra": {
28+
"branch-alias": {
29+
"dev-main": "2.x-dev"
30+
}
31+
}
32+
}

0 commit comments

Comments
 (0)