Skip to content

Commit 8b8179e

Browse files
authored
Merge pull request dwmkerr#477 from dwmkerr/docs/book-contributor-credit
docs: note editorial process, contributor credit and possible book
2 parents 3a48d3e + cb78483 commit 8b8179e

6 files changed

Lines changed: 34 additions & 122 deletions

File tree

.github/contributing.md

Lines changed: 31 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,14 @@
33
<!-- vim-markdown-toc GFM -->
44

55
- [Goal of the Project](#goal-of-the-project)
6+
- [Editorial Process](#editorial-process)
67
- [Example Law: The Law of Leaky Abstractions](#example-law-the-law-of-leaky-abstractions)
78
- [Translations](#translations)
89
- [How do I know if a law is relevant?](#how-do-i-know-if-a-law-is-relevant)
910
- [How do I know if a law is 'well known' enough?](#how-do-i-know-if-a-law-is-well-known-enough)
1011
- [Use of Images](#use-of-images)
1112
- [Developer Guide](#developer-guide)
13+
- [Contributor Credit and a Possible Book](#contributor-credit-and-a-possible-book)
1214

1315
<!-- vim-markdown-toc -->
1416

@@ -33,12 +35,23 @@ Some other tips:
3335
- Do not advocate for the law, or aim to be opinionated on the correctness or incorrectness of the law, as this repository is simply the descriptions and links.
3436
- Avoid 'you' when writing. For example, prefer "This law suggests refactoring should be avoided when..." rather than "you should avoid refactoring when...". This keeps the style slightly more formal and avoids seeming like advocation of a law.
3537

36-
An example law is shown below, which covers most of the key points:
38+
## Editorial Process
39+
40+
Every contribution is edited, either before it is merged or shortly afterwards. In practice this means changes to style, tone, structure and length, a check that the description is correct and relevant, and a check that quotes and images are properly attributed.
41+
42+
A law may therefore end up reading quite differently from the version that was submitted. This is not a comment on the quality of the contribution. The aim is to keep a long document in a single voice, and to keep every entry to the same shape and length.
43+
44+
Two things make this much easier:
45+
46+
- Do not copy and paste text from other sources, unless it is explicitly quoted and attributed. See [Use of Images](#use-of-images) for the equivalent point about pictures.
47+
- Include a link to the source for anything you reference, and the licence for any image.
3748

3849
---
3950

4051
## Example Law: The Law of Leaky Abstractions
4152

53+
An example law is shown below, which covers most of the key points.
54+
4255
[The Law of Leaky Abstractions on Joel on Software](https://www.joelonsoftware.com/2002/11/11/the-law-of-leaky-abstractions/)
4356

4457
> All non-trivial abstractions, to some degree, are leaky.
@@ -87,19 +100,30 @@ A good test is 'If I search for it on Google, will I find it in the first few re
87100

88101
## Use of Images
89102

90-
Please make sure to attribute images properly if you are referencing them. Also, include a white background, as some viewers will be viewing the site in 'Dark Mode' which can make images with a transparent background difficult to read.
103+
Original diagrams are strongly preferred. If you do reference an image from elsewhere, please include the source URL, the author and the licence in the pull request, so that it can be attributed properly. Images without a clear licence cannot be accepted, and images may later be redrawn to keep the artwork consistent.
104+
105+
Also include a white background, as some viewers will be reading in 'Dark Mode', which can make images with a transparent background difficult to read.
91106

92107
## Developer Guide
93108

94109
Where possible, anything which is not the core `README.md` file is kept in the `.github/` folder to keep the landing page for the repository as clean as possible.
95110

96-
To use the makefile, pass its path explicitly, e.g:
111+
The website at [hacker-laws.com](https://hacker-laws.com) is built from `README.md`. To build and serve it locally:
97112

98113
```bash
99-
make -f .github/makefile
114+
cd .github/website
115+
make install
116+
make serve
100117
```
101118

102-
Or create an alias:
119+
Run `make` on its own to see the other targets.
103120

104-
```bash
105-
alias hlmake="make -f .github/makefile"
121+
## Contributor Credit and a Possible Book
122+
123+
This project may in time be turned into a book.
124+
125+
If that happens, every contributor will be credited in an appendix. Contributors are listed by GitHub handle by default. If you would prefer to be credited by name, please say so in your pull request.
126+
127+
By opening a pull request you grant the maintainer a permanent, worldwide, royalty-free and non-exclusive licence to use, edit, translate and publish your contribution in any format, including print and electronic editions which are sold. You keep the copyright in what you wrote, and remain free to use it elsewhere yourself.
128+
129+
The repository stays under [CC BY-SA 4.0](../LICENSE) and will remain free to read.

.github/makefile

Lines changed: 0 additions & 22 deletions
This file was deleted.

.github/workflows/cicd.yaml

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -41,47 +41,6 @@ jobs:
4141
manifest-file: .github/release-please-manifest.json
4242
config-file: .github/release-please-config.json
4343

44-
release-pdf:
45-
runs-on: ubuntu-24.04
46-
needs: release
47-
if: ${{ needs.release.outputs.released }}
48-
steps:
49-
- name: Checkout
50-
uses: actions/checkout@v4
51-
52-
# Set a descriptive version. For PRs it'll be the short sha.
53-
- name: Check Version
54-
run: echo "${VERSION}"
55-
env:
56-
VERSION: ${{ needs.release.outputs.tag }}
57-
58-
# Set a descriptive version. For PRs it'll be the short sha.
59-
- name: Prepare Markdown
60-
run: |
61-
# Set the env vars we use (version set for clarity).
62-
export DATE=$(date +%F)
63-
export VERSION="${VERSION}"
64-
make -f .github/makefile prepare-markdown
65-
env:
66-
VERSION: ${{ needs.release.outputs.tag }}
67-
68-
# Create the PDF files.
69-
- name: Create PDF
70-
run: make -f .github/makefile create-pdf
71-
72-
# Publish the PDF and intermediate markdown as an artifact.
73-
# - name: Publish PDF Artifact
74-
# uses: actions/upload-artifact@3
75-
# with:
76-
# name: hacker-laws.pdf
77-
# path: hacker-laws.pdf
78-
79-
- name: Attach assets to GitHub Release
80-
env:
81-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
82-
run: |
83-
gh release upload "${{ needs.release.outputs.tag }}" --clobber hacker-laws.pdf hacker-laws.md
84-
8544
deploy:
8645
environment:
8746
name: github-pages

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
.DS_Store
2+
scratch/

README.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
- 🧠 Check out my new project [Terminal AI](https://github.com/dwmkerr/terminal-ai)
99
- ☕️ Like this project? Consider [buying me a coffee with a one-off donation](https://github.com/sponsors/dwmkerr?frequency=one-time)
1010
- 🎧 Listen to the podcast [The Changelog - Laws for Hackers to Live By](https://changelog.com/podcast/403)
11-
- 📖 Download the [PDF eBook](https://github.com/dwmkerr/hacker-laws/releases/latest/download/hacker-laws.pdf)
1211
- 🌏 See the Translations: [🇧🇷](./translations/pt-BR.md) [🇨🇳](https://github.com/nusr/hacker-laws-zh) [🇫🇷](./translations/fr.md) [🇮🇹](./translations/it-IT.md) [🇱🇻](./translations/lv.md) [🇰🇷](https://github.com/codeanddonuts/hacker-laws-kr) [🇷🇺](https://github.com/solarrust/hacker-laws) [🇪🇸](./translations/es-ES.md) [🇹🇷](./translations/tr.md) [🇮🇩](./translations/id.md) [🇯🇵](./translations/jp.md) [🇵🇱](./translations/pl.md) [🇻🇳](./translations/vi.md)
1312

1413
---
@@ -88,7 +87,6 @@
8887
- [The Principle of Least Astonishment](#the-principle-of-least-astonishment)
8988
- [Reading List](#reading-list)
9089
- [Online Resources](#online-resources)
91-
- [PDF eBook](#pdf-ebook)
9290
- [Podcast](#podcast)
9391
- [Contributors](#contributors)
9492

@@ -98,6 +96,8 @@
9896

9997
There are lots of laws which people discuss when talking about development. This repository is a reference and overview of some of the most common ones. Please share and submit PRs!
10098

99+
This project may in time be turned into a book. If it is, all contributors will be credited in an appendix, listed by GitHub handle, or by name if requested in the pull request. See the [Contributing Guidelines](.github/contributing.md) for details.
100+
101101
Warning: This repo contains an explanation of some laws, principles and patterns, but does not _advocate_ for any of them. Whether they should be applied will always be a matter of debate, and greatly dependent on what you are working on.
102102

103103
## Laws
@@ -1216,12 +1216,6 @@ Some useful resources and reading.
12161216

12171217
- [CB Insights: 8 Laws Driving Success In Tech: Amazon's 2-Pizza Rule, The 80/20 Principle, & More](https://www.cbinsights.com/research/report/tech-laws-success-failure) - an interesting write up of some laws which have been highly influential in technology.
12181218

1219-
## PDF eBook
1220-
1221-
The project is available as a PDF eBook, [download the latest PDF eBook with this link](https://github.com/dwmkerr/hacker-laws/releases/latest/download/hacker-laws.pdf) or check the [release](https://github.com/dwmkerr/hacker-laws/releases) page for older versions.
1222-
1223-
A new version of the eBook is created automatically when a new version tag is pushed.
1224-
12251219
## Podcast
12261220

12271221
Hacker Laws has been featured in [The Changelog](https://changelog.com/podcast/403), you can check out the Podcast episode with the link below:

scripts/prepare-markdown-for-ebook.sh

Lines changed: 0 additions & 44 deletions
This file was deleted.

0 commit comments

Comments
 (0)