Skip to content

Commit b399069

Browse files
authored
Merge pull request #356 from shapehq/develop
Deploy to production
2 parents 79bc2eb + 5e22c8b commit b399069

File tree

18 files changed

+287
-177
lines changed

18 files changed

+287
-177
lines changed

.env.example

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
SHAPE_DOCS_BASE_URL=http://localhost:3000
2-
SHAPE_DOCS_PROJECT_CONFIGURATION_FILENAME=.shape-docs.yml
3-
NEXT_PUBLIC_SHAPE_DOCS_TITLE=Shape Docs
4-
NEXT_PUBLIC_SHAPE_DOCS_DESCRIPTION=Documentation for Shape's APIs
5-
NEXT_PUBLIC_SHAPE_DOCS_HELP_URL=https://github.com/shapehq/shape-docs/wiki
1+
FRAMNA_DOCS_BASE_URL=http://localhost:3000
2+
FRAMNA_DOCS_TITLE=Framna Docs
3+
FRAMNA_DOCS_DESCRIPTION=Documentation for Framna's APIs
4+
FRAMNA_DOCS_HELP_URL=https://github.com/shapehq/framna-docs/wiki
5+
FRAMNA_DOCS_PROJECT_CONFIGURATION_FILENAME=.shape-docs.yml
66
NEXTAUTH_URL_INTERNAL=http://localhost:3000
77
NEXTAUTH_SECRET=use [openssl rand -base64 32] to generate a 32 bytes value
88
REDIS_URL=localhost
99
POSTGRESQL_HOST=localhost
1010
POSTGRESQL_USER=dbuser
1111
POSTGRESQL_PASSWORD=
12-
POSTGRESQL_DB=shape-docs
12+
POSTGRESQL_DB=framna-docs
1313
REPOSITORY_NAME_SUFFIX=-openapi
1414
HIDDEN_REPOSITORIES=
1515
NEW_PROJECT_TEMPLATE_REPOSITORY=shapehq/starter-openapi

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ body:
2929
id: expected-behavior
3030
attributes:
3131
label: What is the expected behavior?
32-
description: Please describe the behavior you expect of Shape Docs.
33-
placeholder: I expect that Shape Docs would...
32+
description: Please describe the behavior you expect of Framna Docs.
33+
placeholder: I expect that Framna Docs would...
3434
validations:
3535
required: true

README.md

Lines changed: 42 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
<div align="center">
2-
<img width="200" src="https://github.com/shapehq/shape-docs/raw/main/logo.png" alt="Shape Docs logo" />
2+
<img width="200" src="https://github.com/shapehq/framna-docs/raw/main/logo.png" alt="Framna Docs logo" />
33
</div>
44

55
<div align="center">
6-
<h3>👋 Welcome to Shape Docs</h3>
6+
<h3>👋 Welcome to Framna Docs</h3>
77
<h4>Self-hosted web portal that collects OpenAPI documentation and facilitates spec-driven development, built with GitHub-based authorization.</h4>
88
</div>
99

1010
<div align="center">
11-
<a href="https://github.com/shapehq/shape-docs/actions/workflows/build.yml"><img src="https://github.com/shapehq/shape-docs/actions/workflows/build.yml/badge.svg"></a>
12-
<a href="https://github.com/shapehq/shape-docs/actions/workflows/run-unit-tests.yml"><img src="https://github.com/shapehq/shape-docs/actions/workflows/run-unit-tests.yml/badge.svg"></a>
13-
<a href="https://github.com/shapehq/shape-docs/actions/workflows/test-sql-queries.yml"><img src="https://github.com/shapehq/shape-docs/actions/workflows/test-sql-queries.yml/badge.svg"></a>
14-
<a href="https://github.com/shapehq/shape-docs/actions/workflows/lint.yml"><img src="https://github.com/shapehq/shape-docs/actions/workflows/lint.yml/badge.svg"></a>
15-
<a href="https://github.com/shapehq/shape-docs/actions/workflows/build-docker-image"><img src="https://github.com/shapehq/shape-docs/actions/workflows/build-docker-image.yml/badge.svg"></a>
11+
<a href="https://github.com/shapehq/framna-docs/actions/workflows/build.yml"><img src="https://github.com/shapehq/framna-docs/actions/workflows/build.yml/badge.svg"></a>
12+
<a href="https://github.com/shapehq/framna-docs/actions/workflows/run-unit-tests.yml"><img src="https://github.com/shapehq/framna-docs/actions/workflows/run-unit-tests.yml/badge.svg"></a>
13+
<a href="https://github.com/shapehq/framna-docs/actions/workflows/test-sql-queries.yml"><img src="https://github.com/shapehq/framna-docs/actions/workflows/test-sql-queries.yml/badge.svg"></a>
14+
<a href="https://github.com/shapehq/framna-docs/actions/workflows/lint.yml"><img src="https://github.com/shapehq/framna-docs/actions/workflows/lint.yml/badge.svg"></a>
15+
<a href="https://github.com/shapehq/framna-docs/actions/workflows/build-docker-image"><img src="https://github.com/shapehq/framna-docs/actions/workflows/build-docker-image.yml/badge.svg"></a>
1616
</div>
1717

1818
---
@@ -21,52 +21,69 @@
2121
<a href="#-getting-started">🚀 Getting Started</a>&nbsp;&nbsp;&nbsp;&nbsp;
2222
<a href="#-how-does-it-work">👨‍🔧 How does it work?</a>&nbsp;&nbsp;&nbsp;&nbsp;
2323
<a href="#-how-can-i-contribute">👩‍💻 How can I contribute?</a>&nbsp;&nbsp;&nbsp;&nbsp;
24-
<a href="https://github.com/shapehq/shape-docs/wiki">📖 Wiki</a>
24+
<a href="https://github.com/shapehq/framna-docs/wiki">📖 Wiki</a>
2525
</div>
2626

2727
<hr />
2828

29-
Shape Docs makes managing and previewing OpenAPI documentation a breeze, streamlining spec-driven development. With GitHub-based authorization, you can easily control who accesses your docs. Shape Docs comments on pull requests that tweak your OpenAPI specs, giving you preview URLs to ensure every update is well-reviewed.
29+
Framna Docs makes managing and previewing OpenAPI documentation a breeze, streamlining spec-driven development. With GitHub-based authorization, you can easily control who accesses your docs. Framna Docs comments on pull requests that tweak your OpenAPI specs, giving you preview URLs to ensure every update is well-reviewed.
3030

3131
<div align="center">
32-
<img width="600" src="https://github.com/shapehq/shape-docs/raw/main/wiki/home.png?raw=true" alt="Screenshot of Shape Docs"/>
32+
<img width="600" src="https://github.com/shapehq/framna-docs/raw/main/wiki/home.png?raw=true" alt="Screenshot of Framna Docs"/>
3333
</div>
3434

3535
## 🚀 Getting Started
3636

37-
Please refer to the following articles in [the wiki](https://github.com/shapehq/shape-docs/wiki) to get started with Shape Docs.
37+
Please refer to the following articles in [the wiki](https://github.com/shapehq/framna-docs/wiki) to get started with Framna Docs.
3838

39-
- [Adding Documentation to Shape Docs](https://github.com/shapehq/shape-docs/wiki/Adding-Documentation-to-Shape-Docs)
40-
- [Browsing Documentation](https://github.com/shapehq/shape-docs/wiki/Browsing-Documentation)
41-
- [Updating Documentation](https://github.com/shapehq/shape-docs/wiki/Updating-Documentation)
42-
- [Deploying Shape Docs](https://github.com/shapehq/shape-docs/wiki/Deploying-Shape-Docs)
39+
- [Adding Documentation to Framna Docs](https://github.com/shapehq/framna-docs/wiki/Adding-Documentation-to-Framna-Docs)
40+
- [Browsing Documentation](https://github.com/shapehq/framna-docs/wiki/Browsing-Documentation)
41+
- [Updating Documentation](https://github.com/shapehq/framna-docs/wiki/Updating-Documentation)
42+
- [Deploying Framna Docs](https://github.com/shapehq/framna-docs/wiki/Deploying-Framna-Docs)
4343

4444
## 👨‍🔧 How does it work?
4545

46-
Shape Docs uses [OpenAPI specifications](https://swagger.io) from GitHub repositories. Users log in with their GitHub account to access documentation for projects they have access to. A repository only needs an OpenAPI spec to be recognized by Shape Docs, but customization is possible with a .shape-docs.yml file. Here's an example:
46+
Framna Docs uses [OpenAPI specifications](https://swagger.io) from GitHub repositories. Users log in with their GitHub account to access documentation for projects they have access to. A repository only needs an OpenAPI spec to be recognized by Framna Docs, but customization is possible with a .framna-docs.yml file. Here's an example:
4747

48-
<img width="650" src="https://github.com/shapehq/shape-docs/raw/main/wiki/example-openapi-repository-with-config.png?raw=true"/>
48+
<img width="650" src="https://github.com/shapehq/framna-docs/raw/main/wiki/example-openapi-repository-with-config.png?raw=true"/>
4949

50-
Shape Docs supports spec-driven development by requiring OpenAPI specs in GitHub repos, ensuring version control and peer review. When a pull request is opened, Shape Docs comments with links to preview the documentation:
50+
Framna Docs supports spec-driven development by requiring OpenAPI specs in GitHub repos, ensuring version control and peer review. When a pull request is opened, Framna Docs comments with links to preview the documentation:
5151

52-
<img width="760" src="https://github.com/shapehq/shape-docs/raw/main/wiki/pr-comment.png?raw=true"/>
52+
<img width="760" src="https://github.com/shapehq/framna-docs/raw/main/wiki/pr-comment.png?raw=true"/>
5353

54-
Learn more from the [Adding Documentation](https://github.com/shapehq/shape-docs/wiki/Adding-Documentation-to-Shape-Docs), [Browsing Documentation](https://github.com/shapehq/shape-docs/wiki/Browsing-Documentation), and [Updating Documentation](https://github.com/shapehq/shape-docs/wiki/Updating-Documentation) articles in the wiki.
54+
Learn more from the [Adding Documentation](https://github.com/shapehq/framna-docs/wiki/Adding-Documentation-to-Framna-Docs), [Browsing Documentation](https://github.com/shapehq/framna-docs/wiki/Browsing-Documentation), and [Updating Documentation](https://github.com/shapehq/framna-docs/wiki/Updating-Documentation) articles in the wiki.
5555

5656
## 👩‍💻 How can I contribute?
5757

58-
Pull requests with bugfixes and new features are much appreciated. We are happy to review PRs and merge them once they are ready, as long as they contain changes that fit within the vision of Shape Docs.
58+
Pull requests with bugfixes and new features are much appreciated. We are happy to review PRs and merge them once they are ready, as long as they contain changes that fit within the vision of Framna Docs.
5959

60-
Clone the repository and consult the articles on [running Shape Docs locally](https://github.com/shapehq/shape-docs/wiki/Running-Shape-Docs-Locally) and [contributing](https://github.com/shapehq/shape-docs/wiki/Contributing) to get started contributing changes the project.
60+
Clone the repository and consult the articles on [running Framna Docs locally](https://github.com/shapehq/framna-docs/wiki/Running-Framna-Docs-Locally) and [contributing](https://github.com/shapehq/framna-docs/wiki/Contributing) to get started contributing changes the project.
6161

6262
```bash
63-
git clone git@github.com:shapehq/shape-docs.git
63+
git clone git@github.com:shapehq/framna-docs.git
6464
```
6565

66+
## 🔀 Git Workflow
67+
68+
Two long-lived branches exist
69+
70+
* **main** (stable/release - deploy to a **production** environment)
71+
* **develop** (integration - deploy to a **staging** environment)
72+
73+
**Do's 👍**
74+
75+
1. Features are branched off from `develop` and merged back in using a PR when ready. Rebase or merge `develop` in to keep the feature branch up to date. Squash merge the feature branch into `develop`.
76+
2. `develop` is merged into `main` whenever a new release is made. Only regular merge commits are allowed in this case. You do not need to "bring develop up to date" with `main` before merging.
77+
3. A hotfix is applied by branching out from `main`. The hotfix branch _must_ be merged into both `main` and `develop`.
78+
79+
**Don'ts 🙅‍♂️**
80+
81+
1. Never squash merge `develop` into `main` ☠️
82+
6683
## ❤️ The Product of a Shape Weekend
6784

68-
Every year we go on Shape Weekend, three days where all employees in Shape get together for a hackathon to build amazing products. In 2023, a team of Shape developers with a passion for documentation and spec-driven development built Shape Docs and we've used it daily ever since!
85+
Every year we go on Shape Weekend, three days where all employees in Shape get together for a hackathon to build amazing products. In 2023, a team of Shape developers with a passion for documentation and spec-driven development built Framna Docs and we've used it daily ever since!
6986

7087
---
7188

72-
Shape Docks is built with ❤️ by [Shape](https://shape.dk) in Denmark. Oh, and [we are hiring](https://careers.shape.dk) 🤗
89+
Framna Docs is built with ❤️ by [Shape](https://shape.dk) in Denmark. Oh, and [we are hiring](https://careers.shape.dk) 🤗

__test__/projects/updateWindowTitle.test.ts

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,9 @@
11
import { updateWindowTitle } from "@/features/projects/domain"
22

3-
test("It uses default title when there is no selection", async () => {
4-
const store: { title: string } = { title: "" }
5-
updateWindowTitle({
6-
storage: store,
7-
defaultTitle: "Demo Docs"
8-
})
9-
expect(store.title).toEqual("Demo Docs")
10-
})
11-
123
test("It leaves out specification when the specification has a generic name", async () => {
134
const store: { title: string } = { title: "" }
145
updateWindowTitle({
156
storage: store,
16-
defaultTitle: "Demo Docs",
177
project: {
188
id: "foo",
199
name: "foo",
@@ -49,7 +39,6 @@ test("It leaves out version when it is the defualt version", async () => {
4939
const store: { title: string } = { title: "" }
5040
updateWindowTitle({
5141
storage: store,
52-
defaultTitle: "Demo Docs",
5342
project: {
5443
id: "foo",
5544
name: "foo",
@@ -81,7 +70,6 @@ test("It adds version when it is not the defualt version", async () => {
8170
const store: { title: string } = { title: "" }
8271
updateWindowTitle({
8372
storage: store,
84-
defaultTitle: "Demo Docs",
8573
project: {
8674
id: "foo",
8775
name: "foo",

0 commit comments

Comments
 (0)