Skip to content

Commit fc5a690

Browse files
authored
Shorten pattern URLs in the book (InnerSourceCommons#307)
* Change to subfolder structure (path in URL) e.g. "p/innersource-portal" * Improve documentation of the book generation. incl description of book-staging
1 parent b93001d commit fc5a690

File tree

4 files changed

+13
-11
lines changed

4 files changed

+13
-11
lines changed

.github/workflows/book.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
push:
55
branches:
66
- "master"
7+
- "book-staging"
78

89
jobs:
910
book-toc-generation:

book/README.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
# How to generate the InnerSource Patterns gitbook
22

3-
Whenever changes to the [InnerSource Patterns][InnerSourcePatterns] GitHub repository are made, a new version of our InnerSource Patterns book is published at gitbook.com.
4-
5-
The files in the `./book` folder contain generator scripts and some extra content required to create our gitbook.
3+
Whenever changes to the [InnerSource Patterns][InnerSourcePatterns] GitHub repository are made, a new version of our InnerSource Patterns book is published at [patterns.innersourcecommons.org][book_production].
64

75
## Where is the book published?
86

97
The most up-to-date version of the book is available for readers/consumers at [patterns.innersourcecommons.org][book_production].
108

11-
We also have a [Staging version][book_staging], used by the editors/producers of the book for testing purposes.
9+
We also have a [Staging version][book_staging], used by the editors/producers of the book for testing purposes. If you want to make any structural changes to the book, please send a PR to merge your changes into the `book-staging` branch. That way we can test your changes on the Staging version first, before they go live.
1210

1311
## Which patterns are published?
1412

15-
In the book we publish the patterns of maturity **Structured** (Level 2) or **Validated** (Level 3). For more on these maturity levels see the [Contributor Handbook](../meta/contributor-handbook.md).
13+
The book contains patterns of maturity **Structured** (Level 2) or **Validated** (Level 3). **Initial** (Level 1) patterns are not published in the book, because those are still subject to a lot of change, and have likely not even proven to work yet. For more on these maturity levels see the [Contributor Handbook](../meta/contributor-handbook.md).
1614

1715
## How does it work?
1816

17+
The `./book` folder contains generator scripts and some extra content required to create the gitbook.
18+
1919
- `/.gitbook.yaml` - Holds basic configuration for the gitbook service. This never needs to be changed.
2020
- `/book/toc.md` - An auto-generated table of contents (ToC) for the book i.e. a list of all pages and patterns that are part of the book. The ToC is what you see on the left-hand-side menu in gitbooks.
2121
- `/book/generate_toc.rb` - Takes patterns of maturity **Structured** and **Validated**, extracts title and patlet, and injects this info into `/book/toc_template.md`. The output is written to `/book/toc.md`.
@@ -27,15 +27,16 @@ In the book we publish the patterns of maturity **Structured** (Level 2) or **Va
2727

2828
These patterns are already publicly available in the [InnerSource Patterns][InnerSourcePatterns] GitHub repo. So why publish such a book at all?
2929

30-
We think there are a couple of good reasons to publish the InnerSource patterns as a gitbook:
30+
There are a couple of good reasons to publish the InnerSource patterns as a gitbook:
3131

3232
* (consumers) have something that is “nicer” to read than things on GitHub
33-
* (consumers) have stable URLs for patterns i.e. even if the files move in the folder structure in the repo, the URL of the pattern stay the same
33+
* (consumers) search for keywords across all patterns
3434
* (consumers) export book as PDF and read on other devices
35-
* (producers) a motivation for pattern authors (and all contributors) to level up patterns from 1-initial, as only 2-structured and 3-validated are published in the book
35+
* (consumers) have stable URLs for patterns that can be used as references in other material e.g. from the Learning Path (i.e. even if the files move in the folder structure in the GitHub repo, the URL of the pattern stay the same)
36+
* (producers) a motivation for pattern authors and all contributors to level up patterns from 1-initial, as only 2-structured and 3-validated are published in the book
3637
* (producers) a motivation for us to introduce more specific quality guidelines for level 2+3, so that we can be even more proud of the content in the book :)
3738
* (producers) learn which patterns are most interesting for readers (e.g. through Google Analytics)
3839

3940
[InnerSourcePatterns]: https://github.com/InnerSourceCommons/InnerSourcePatterns
4041
[book_production]: https://patterns.innersourcecommons.org
41-
[book_staging]: https://innersourcecommons.gitbook.io/innersource-patterns-staging/v/book/
42+
[book_staging]: https://innersourcecommons.gitbook.io/innersource-patterns-staging/v/book-staging/

book/toc.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Instead edit toc_template.md
1414

1515
<img src="./innersource-program-mind-map.png" title="InnerSource Patterns as a Mind Map">
1616

17-
## Patterns
17+
## Patterns <a id="p"></a>
1818

1919
* [30 Day Warranty](../patterns/2-structured/30-day-warranty.md) - When accepting contributions from outside of your own team, there is a natural aversion to taking responsibility for code not written by the team itself. Through the 30 Day Warranty the contributing team consents to provide bug fixes to the receiving team, which will increase the level of trust between both teams and makes it more likely that contributions get accepted.
2020
* [Common Requirements](../patterns/2-structured/common-requirements.md) - Common code in a shared repository isn't meeting the needs of all the project-teams that want to use it; this is solved through requirements alignment and refactoring.

book/toc_template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Instead edit toc_template.md
1414

1515
<img src="./innersource-program-mind-map.png" title="InnerSource Patterns as a Mind Map">
1616

17-
## Patterns
17+
## Patterns <a id="p"></a>
1818

1919
<<PATTERS_HERE>>
2020

0 commit comments

Comments
 (0)