Skip to content

Commit fb5d31e

Browse files
authored
Generate mind map automatically (via GHA) (#348)
Adds a GHA to generate mind map automatically. Also updates corresponding documentation and removes duplicate PNG files.
1 parent 1aee891 commit fb5d31e

11 files changed

+2856
-16
lines changed
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Generate Mindmap
2+
3+
on:
4+
push:
5+
branches:
6+
- "main"
7+
pull_request:
8+
paths:
9+
- ".github/workflows/generate-mindmap.yml"
10+
- "pattern-categorization/innersource-program-mind-map.md"
11+
12+
defaults:
13+
run:
14+
working-directory: pattern-categorization
15+
16+
jobs:
17+
generate-mindmap:
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v2
21+
- name: Use Node.js
22+
uses: actions/setup-node@v2
23+
with:
24+
node-version: 12.x
25+
cache: 'npm'
26+
cache-dependency-path: pattern-categorization/package-lock.json
27+
- name: Install Node.js dependencies
28+
run: npm install
29+
- name: Run Markmap
30+
run: npx markmap --no-toolbar innersource-program-mind-map.md -o innersource-program-mind-map.html
31+
- name: Screenshot Markmap Website
32+
id: screenshot-generator
33+
uses: swinton/[email protected]
34+
with:
35+
source: pattern-categorization/innersource-program-mind-map.html
36+
destination: innersource-program-mind-map.png
37+
full-page: false
38+
- name: Copy Screenshot
39+
run: cp ${{ steps.screenshot-generator.outputs.path }} .
40+
- name: Reduce Screenshot Size (PNG)
41+
run: npx optipng innersource-program-mind-map.png
42+
- name: Commit Changes
43+
uses: stefanzweifel/git-auto-commit-action@v4
44+
with:
45+
commit_message: Re-creating markmap and screenshot

book/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ The `./book` folder contains generator scripts and some extra content required t
2222
- `.github/workflows/book.yml` - A GitHub Action that triggers the execution of `/book/generate_toc.rb`.
2323
- `/book/introduction.md` - The introduction to our book. This content is what the reader sees first when they open the book. The current content is based on [README.md](../README.md). We may need to modify this content even further, to address the readers of the book more specifically, rather than the readers of our GitHub repository.
2424
- `/book/contribute.md` - Information about how to contribute to this book.
25+
- `/book/explore-patterns.md` - Dedicated page in the book that highlights the mind map of all patterns.
2526

2627
## Objectives of the book
2728

book/explore-patterns.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Now how to make it easy for readers to discover the patterns that can help them
66

77
For this purpose we provide this mind map. It **categorizes patterns based on the different phases of an InnerSource Program**, and the challenges that might appear in the respective phases.
88

9-
<img src="./innersource-program-mind-map.png" title="InnerSource Patterns as a Mind Map">
9+
<img src="../pattern-categorization/innersource-program-mind-map.png" title="InnerSource Patterns as a Mind Map">
1010

1111
## Improve this Mind Map
1212

book/innersource-program-mind-map.png

-403 KB
Binary file not shown.

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
* [Explore Patterns](../book/explore-patterns.md)
1515
* [Contribute to this book](../book/contribute.md)
1616

17-
<img src="./innersource-program-mind-map.png" title="InnerSource Patterns as a Mind Map">
17+
<img src="../pattern-categorization/innersource-program-mind-map.png" title="InnerSource Patterns as a Mind Map">
1818

1919
## Patterns <a id="p"></a>
2020

pattern-categorization/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules/

pattern-categorization/README.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,34 +6,38 @@ Now how do we make it easier for readers to discover the patterns that can help
66

77
## InnerSource Program Mind Map
88

9-
This first categorization effort uses a mind map to categorize patterns based on the different phases of an InnerSource Program, and the challenges that might appear in the respective phases. See [innersource-program-mind-map.html](innersource-program-mind-map.html). Note that this is still an incomplete visualization i.e. it does not contain all of our patterns.
9+
This first categorization effort uses a mind map to categorize patterns based on the different phases of an InnerSource Program, and the challenges that might appear in the respective phases. See [innersource-program-mind-map.html](innersource-program-mind-map.html). Note that this mind map contains only the patterns that are published in our book (i.e. Level 2-Structured and higher).
1010

1111
In the mind map you will see patterns categorized from left to right in increasing levels of detail.
1212

13-
The logic for these levels is:
13+
The logic for these levels is (from left to right):
1414

1515
- level 0: the InnerSource program itself (as the root)
1616
- level 1: phase of an InnerSource Program
1717
- level 2: problem category
1818
- level 3: specific problem occurring in an InnerSource context
1919
- level 4: pattern (solution to the problem)
2020

21-
To add new patterns to the mind map, edit the source file `innersource-program-mind-map.md`, and then regenerate the visualization like this:
21+
## Adding a Pattern to the Mind Map
22+
23+
To add new patterns to the mind map, edit the file [innersource-program-mind-map.md](innersource-program-mind-map.md). Also see the explanation of the different levels in the mind map above.
24+
25+
Then create a PR with your changes. This triggers an [action](https://github.com/InnerSourceCommons/InnerSourcePatterns/actions/workflows/generate-mindmap.yml) that generates the mind map in HTML and PNG format, and adds those to your PR.
26+
27+
To test your changes locally, you can also generate the mind map yourself like this:
2228

2329
```
24-
npm install markmap-lib -g
30+
npm install -g markmap-cli
2531
markmap innersource-program-mind-map.md
2632
```
2733

28-
Once this is done please replace `book/innersource-program-mind-map.jpg` with an updated version of this mind map.
29-
3034
## Future Ideas for Categorization
3135

3236
We have some other ideas for categories by which the InnerSource Patterns could be grouped.
3337

34-
One is **management and empowerment**. Some patterns help to manage, govern, mitigate risk. Some other patterns help to empower, attract, build communities. This categorization can help others to quickly find the group of patterns that fit their needs.
35-
36-
Another angle is **single project vs organization**. Some patterns are applicable to single project, while others are organizational effort. For people working on specific initiative, single project level patterns might be more interesting. For people working on scaling InnerSource, organizational patterns are important.
38+
* **Single Project vs Organization** - Some patterns are applicable to single project, while others are organizational effort. For people working on specific initiative, single project level patterns might be more interesting. For people working on scaling InnerSource, organizational patterns are important.
39+
* **InnerSource Adoption Obstacles** - The [2020 State of InnerSource Research](https://innersourcecommons.org/documents/surveys/State.of.InnerSource.Report.2020.pdf) identifies various obstacles for InnerSource adoption (see page 25). We could identify the patterns that help address each of these obstacles.
40+
* **Management and Empowerment** - Some patterns help to manage, govern, mitigate risk. Some other patterns help to empower, attract, build communities. This categorization can help others to quickly find the group of patterns that fit their needs.
3741

3842
## References
3943

pattern-categorization/innersource-program-mind-map.html

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,11 @@
2020
</head>
2121
<body>
2222
<svg id="mindmap"></svg>
23-
<script src="https://cdn.jsdelivr.net/npm/d3@5"></script><script src="https://cdn.jsdelivr.net/npm/markmap-lib@0.7.6/dist/browser/view.min.js"></script><script>((data, ...processors) => {
23+
<script src="https://cdn.jsdelivr.net/npm/d3@6.6.0"></script><script src="https://cdn.jsdelivr.net/npm/markmap-view@0.2.6"></script><script>((getMarkmap, getOptions, data) => {
2424
const {
2525
Markmap
26-
} = window.markmap;
27-
Markmap.processors = processors;
28-
Markmap.create('svg#mindmap', null, data);
29-
})({"t":"heading","d":1,"v":"<a href=\"https://patterns.innersourcecommons.org/toc\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">InnerSource Program</a>","c":[{"t":"heading","d":2,"v":"Begin","c":[{"t":"heading","d":3,"v":"Program Setup","c":[{"t":"heading","d":4,"v":"Management hesitates to invest in InnerSource","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/start-as-experiment\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Start as an Experiment</a>"}]},{"t":"heading","d":4,"v":"Slow community growth hinders InnerSource","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/dedicated-community-leader\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Dedicated Community Leader</a>"}]}]},{"t":"heading","d":3,"v":"Project Setup","c":[{"t":"heading","d":4,"v":"Hard to assess a project quickly","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/base-documentation\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Standard Base Documentation</a>"}]},{"t":"heading","d":4,"v":"Ad-hoc communication hinders project growth","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/communication-tooling\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Communication Tooling</a>"}]},{"t":"heading","d":4,"v":"Intransparent roadmap and direction of the project","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/issue-tracker\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Issue Tracker Use Cases</a>"}]}]}]},{"t":"heading","d":2,"v":"Adoption","c":[{"t":"heading","d":3,"v":"Valuation Challenges","c":[{"t":"heading","d":4,"v":"How to measure a project's business value","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/crossteam-project-valuation\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Cross-Team Project Valuation</a>"}]}]},{"t":"heading","d":3,"v":"Cultural Challenges","c":[{"t":"heading","d":4,"v":"Unrecognized effort","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/praise-participants\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Praise Participants</a>"},{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/trusted-committer\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Trusted Committer</a>"}]}]},{"t":"heading","d":3,"v":"Technical Challenges","c":[{"t":"heading","d":4,"v":"Not meeting everyone's needs","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/common-requirements\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Common Requirements</a>"}]},{"t":"heading","d":4,"v":"Fear of shared support responsibility","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/service-vs-library\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Service vs. Library</a>"}]}]},{"t":"heading","d":3,"v":"Organizational Challenges","c":[{"t":"heading","d":4,"v":"Discouragement of contributing resource","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/contracted-contributor\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Contracted Contributor</a>"}]},{"t":"heading","d":4,"v":"Rejection of accepting contribution","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/30-day-warranty\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">30 Day Warranty</a>"}]},{"t":"heading","d":4,"v":"Radical change of management","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/review-committee\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Review Committee</a>"}]},{"t":"heading","d":4,"v":"Fear of shared support responsibility","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/service-vs-library\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Service vs. Library</a>"}]},{"t":"heading","d":4,"v":"Not enough maintainers to scale","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/trusted-committer\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Trusted Committer</a>"}]},{"t":"heading","d":4,"v":"Difficult cross-team coordination","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/transparent-cross-team-decision-making-using-rfcs\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Transparent Cross-Team Decision Making using RFCs</a>"}]}]},{"t":"heading","d":3,"v":"Cross Legal Entities Challenges","c":[{"t":"heading","d":4,"v":"Concern on legal liabilities or cross-company accounting","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/innersource-license\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">InnerSource License</a>"}]}]}]},{"t":"heading","d":2,"v":"Grow","c":[{"t":"heading","d":3,"v":"Discovery Challenges","c":[{"t":"heading","d":4,"v":"Can't find matching projects","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/gig-marketplace\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Gig Marketplace</a>"},{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/innersource-portal\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">InnerSource Portal</a>"}]},{"t":"heading","d":4,"v":"Difficult to find active projects","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/repository-activity-score\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Repository Activity Score</a>"}]}]}]},{"t":"heading","d":2,"v":"Scale","c":[{"t":"heading","d":3,"v":"Self Education/Improvement Challenges","c":[{"t":"heading","d":4,"v":"Not aware of InnerSource best practices","c":[{"t":"heading","d":5,"v":"<a href=\"https://patterns.innersourcecommons.org/p/maturity-model\" title=\"\" target=\"_blank\" rel=\"noopener noreferrer\">Maturity Model</a>"}]}]}]}]})</script>
26+
} = getMarkmap();
27+
window.mm = Markmap.create('svg#mindmap', getOptions == null ? void 0 : getOptions(), data);
28+
})(() => window.markmap,null,{"t":"heading","d":1,"p":{"lines":[0,1]},"v":"<a href=\"https://patterns.innersourcecommons.org/toc\">InnerSource Program</a>","c":[{"t":"heading","d":2,"p":{"lines":[2,3]},"v":"Begin","c":[{"t":"heading","d":3,"p":{"lines":[4,5]},"v":"Program Setup","c":[{"t":"heading","d":4,"p":{"lines":[6,7]},"v":"Management hesitates to invest in InnerSource","c":[{"t":"heading","d":5,"p":{"lines":[8,9]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/start-as-experiment\">Start as an Experiment</a>"}]},{"t":"heading","d":4,"p":{"lines":[10,11]},"v":"Slow community growth hinders InnerSource","c":[{"t":"heading","d":5,"p":{"lines":[12,13]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/dedicated-community-leader\">Dedicated Community Leader</a>"}]}]},{"t":"heading","d":3,"p":{"lines":[14,15]},"v":"Project Setup","c":[{"t":"heading","d":4,"p":{"lines":[16,17]},"v":"Hard to assess a project quickly","c":[{"t":"heading","d":5,"p":{"lines":[18,19]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/base-documentation\">Standard Base Documentation</a>"}]},{"t":"heading","d":4,"p":{"lines":[20,21]},"v":"Ad-hoc communication hinders project growth","c":[{"t":"heading","d":5,"p":{"lines":[22,23]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/communication-tooling\">Communication Tooling</a>"}]},{"t":"heading","d":4,"p":{"lines":[24,25]},"v":"Intransparent roadmap and direction of the project","c":[{"t":"heading","d":5,"p":{"lines":[26,27]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/issue-tracker\">Issue Tracker Use Cases</a>"}]}]}]},{"t":"heading","d":2,"p":{"lines":[28,29]},"v":"Adoption","c":[{"t":"heading","d":3,"p":{"lines":[30,31]},"v":"Valuation Challenges","c":[{"t":"heading","d":4,"p":{"lines":[32,33]},"v":"How to measure a project's business value","c":[{"t":"heading","d":5,"p":{"lines":[34,35]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/crossteam-project-valuation\">Cross-Team Project Valuation</a>"}]}]},{"t":"heading","d":3,"p":{"lines":[36,37]},"v":"Cultural Challenges","c":[{"t":"heading","d":4,"p":{"lines":[38,39]},"v":"Unrecognized effort","c":[{"t":"heading","d":5,"p":{"lines":[40,41]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/praise-participants\">Praise Participants</a>"},{"t":"heading","d":5,"p":{"lines":[42,43]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/trusted-committer\">Trusted Committer</a>"}]}]},{"t":"heading","d":3,"p":{"lines":[44,45]},"v":"Technical Challenges","c":[{"t":"heading","d":4,"p":{"lines":[46,47]},"v":"Not meeting everyone's needs","c":[{"t":"heading","d":5,"p":{"lines":[48,49]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/common-requirements\">Common Requirements</a>"}]},{"t":"heading","d":4,"p":{"lines":[50,51]},"v":"Fear of shared support responsibility","c":[{"t":"heading","d":5,"p":{"lines":[52,53]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/service-vs-library\">Service vs. Library</a>"}]}]},{"t":"heading","d":3,"p":{"lines":[54,55]},"v":"Organizational Challenges","c":[{"t":"heading","d":4,"p":{"lines":[56,57]},"v":"Discouragement of contributing resource","c":[{"t":"heading","d":5,"p":{"lines":[58,59]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/contracted-contributor\">Contracted Contributor</a>"}]},{"t":"heading","d":4,"p":{"lines":[60,61]},"v":"Rejection of accepting contribution","c":[{"t":"heading","d":5,"p":{"lines":[62,63]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/30-day-warranty\">30 Day Warranty</a>"}]},{"t":"heading","d":4,"p":{"lines":[64,65]},"v":"Radical change of management","c":[{"t":"heading","d":5,"p":{"lines":[66,67]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/review-committee\">Review Committee</a>"}]},{"t":"heading","d":4,"p":{"lines":[68,69]},"v":"Fear of shared support responsibility","c":[{"t":"heading","d":5,"p":{"lines":[70,71]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/service-vs-library\">Service vs. Library</a>"}]},{"t":"heading","d":4,"p":{"lines":[72,73]},"v":"Not enough maintainers to scale","c":[{"t":"heading","d":5,"p":{"lines":[74,75]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/trusted-committer\">Trusted Committer</a>"}]},{"t":"heading","d":4,"p":{"lines":[76,77]},"v":"Difficult cross-team coordination","c":[{"t":"heading","d":5,"p":{"lines":[78,79]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/transparent-cross-team-decision-making-using-rfcs\">Transparent Cross-Team Decision Making using RFCs</a>"}]}]},{"t":"heading","d":3,"p":{"lines":[80,81]},"v":"Cross Legal Entities Challenges","c":[{"t":"heading","d":4,"p":{"lines":[82,83]},"v":"Concern on legal liabilities or cross-company accounting","c":[{"t":"heading","d":5,"p":{"lines":[84,85]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/innersource-license\">InnerSource License</a>"}]}]}]},{"t":"heading","d":2,"p":{"lines":[86,87]},"v":"Grow","c":[{"t":"heading","d":3,"p":{"lines":[88,89]},"v":"Discovery Challenges","c":[{"t":"heading","d":4,"p":{"lines":[90,91]},"v":"Can't find matching projects","c":[{"t":"heading","d":5,"p":{"lines":[92,93]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/gig-marketplace\">Gig Marketplace</a>"},{"t":"heading","d":5,"p":{"lines":[94,95]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/innersource-portal\">InnerSource Portal</a>"}]},{"t":"heading","d":4,"p":{"lines":[96,97]},"v":"Difficult to find active projects","c":[{"t":"heading","d":5,"p":{"lines":[98,99]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/repository-activity-score\">Repository Activity Score</a>"}]}]}]},{"t":"heading","d":2,"p":{"lines":[100,101]},"v":"Scale","c":[{"t":"heading","d":3,"p":{"lines":[102,103]},"v":"Self Education/Improvement Challenges","c":[{"t":"heading","d":4,"p":{"lines":[104,105]},"v":"Not aware of InnerSource best practices","c":[{"t":"heading","d":5,"p":{"lines":[106,107]},"v":"<a href=\"https://patterns.innersourcecommons.org/p/maturity-model\">Maturity Model</a>"}]}]}]}]})</script>
3029
</body>
3130
</html>
331 KB
Loading

0 commit comments

Comments
 (0)