Skip to content

Commit c4d33dc

Browse files
Mustafa Karacwarnermm
Mustafa Kara
andauthored
Enable Notice.txt generation (mattermost#5770)
Signed-off-by: Mustafa Kara <[email protected]> Co-authored-by: Carrie Warner (Mattermost) <[email protected]>
1 parent 9adc29c commit c4d33dc

File tree

5 files changed

+775
-1
lines changed

5 files changed

+775
-1
lines changed

.config/notice-file/Readme.md

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Notice.txt File Configuration
2+
3+
We are automatically generating Notice.txt by using first-level dependencies of the project. The related pipeline uses `config.yaml` stored in this folder.
4+
5+
6+
## Pipfile configuration
7+
For every dependency please add `# Repo: https://github.com/owner/repo` url. Sample:
8+
9+
```
10+
# Add a "copy" button to code blocks in Sphinx (https://sphinx-copybutton.readthedocs.io/en/latest/)
11+
# Repo: https://github.com/executablebooks/sphinx-copybutton
12+
sphinx-copybutton = "0.5.0"
13+
```
14+
15+
## Configuration
16+
17+
Sample:
18+
19+
```
20+
title: "Mattermost Documentation Sphinx Extensions"
21+
copyright: "©2022 Mattermost, Inc. All Rights Reserved. See LICENSE.txt for license information."
22+
description: "This document includes a list of open source components used in Mattermost Documentation Sphinx Extensions, including those that have been modified."
23+
search:
24+
- "Pipfile"
25+
dependencies: []
26+
devDependencies: []
27+
```
28+
29+
| Field | Type | Purpose |
30+
| :-- | :-- | :-- |
31+
| title | string | Field content will be used as a title of the application. See first line of `NOTICE.txt` file. |
32+
| copyright | string | Field content will be used as a copyright message. See second line of `NOTICE.txt` file. |
33+
| description | string | Field content will be used as notice file description. See third line of `NOTICE.txt` file. |
34+
| dependencies | array | If any dependency name mentioned, it will be automatically added even if it is not a first-level dependency. |
35+
| devDependencies | array | If any dependency name mentioned, it will be added when it is referenced in devDependency section. |
36+
| search | array | Pipeline will search for Pipfiles files mentioned here. Globstar format is supported ie. `**/Pipfile`. |

.config/notice-file/config.yaml

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
3+
title: "Mattermost Documentation Sphinx Extensions"
4+
copyright: "©2022 Mattermost, Inc. All Rights Reserved. See LICENSE.txt for license information."
5+
description: "This document includes a list of open source components used in Mattermost Documentation Sphinx Extensions, including those that have been modified."
6+
search:
7+
- "Pipfile"
8+
dependencies: []
9+
devDependencies: []
10+
11+
...

LICENSE.txt

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
Copyright (c) 2022, Mattermost
2+
All rights reserved.
3+
4+
Redistribution and use in source and binary forms, with or without
5+
modification, are permitted provided that the following conditions are met:
6+
7+
* Redistributions of source code must retain the above copyright notice, this
8+
list of conditions and the following disclaimer.
9+
10+
* Redistributions in binary form must reproduce the above copyright notice,
11+
this list of conditions and the following disclaimer in the documentation
12+
and/or other materials provided with the distribution.
13+
14+
* Neither the name of the copyright holder nor the names of its
15+
contributors may be used to endorse or promote products derived from
16+
this software without specific prior written permission.
17+
18+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
22+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
24+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
25+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
26+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

0 commit comments

Comments
 (0)