Skip to content

Commit

Permalink
addes psm-file
Browse files Browse the repository at this point in the history
  • Loading branch information
z1glr committed Oct 28, 2024
1 parent ff1df85 commit c786e23
Show file tree
Hide file tree
Showing 2 changed files with 77 additions and 12 deletions.
22 changes: 11 additions & 11 deletions docs/_files_and_protocol/bible-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,12 @@ JohnCG comes by default with two bible-files:
The books are divided into groups (e. g. "Law" or "Gospels") and those groups into parts (e. g. "Old Testament" or "New Testament").
The group- and part-names aren't predefined and can be changed - for example for localization.

# Structure
# File-Structure
A bible-file is a JSON-file with the file-ending changed to `*.bbl`.

## `name`
Name of the bible-version

## `version`
The version of the bible-file - it's based on semantic versioning:[^1]

The first number indicates the layout-version of the file and is incremented whenever there are changes that are not backwards compatible.
The second number is incremented when the content gets (planned) changes.
The third number is incremented when bugs get fixed.

## `parts`
This object defines different parts of the bible like *Old Testament* or *New Testament*.
The count and name of parts can be freely chosen - only duplicates are forbidden.
Expand All @@ -38,11 +31,17 @@ A section groups multiple books together, for example the Gospels.
A book is defined by its name, abbreviation (called `id`) and an array of the chapters.
The chapters-array has an entry for every chapter with the amount of verses it has.

## Example
## `version`
The version of the bible-file - it's based on semantic versioning[^1]:

The first number indicates the layout-version of the file and is incremented whenever there are changes that are not backwards compatible.
The second number is incremented when the content gets (planned) changes.
The third number is incremented when bugs get fixed.

# Example
```json
{
"name": "King James Version",
"version": "1.0.0",
"parts": {
"Old Testament": [
{
Expand All @@ -61,7 +60,8 @@ The chapters-array has an entry for every chapter with the amount of verses it h
]
}
]
}
},
"version": "1.0.0"
}
```

Expand Down
67 changes: 66 additions & 1 deletion docs/_files_and_protocol/psalm-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,69 @@
title: Psalm file (*.psm)
layout: page
nav_order: 3
---
---
# Psalm file (`*.psm`)
A psalm-file stores the content of a psalm for using it in a playlist.

# File-Structure
A psalm-file is a JSON-file with the file-ending changed to `*.psm`.

## `metadata`
The metadata block defnies all information of the psalm that aren't the text itself.

### caption
Title of the psalm

### `id` (optional)
Number of the psalm in the songbook / hymnal.

### `book` (optional)
Name of the songbook or hymnal.

Currently unused

### `indent` (optional)
Sets wether every second verse should be indented or not.

## `text`
A three-dimensional array with the text split into slides, verses, lines.

## `version`
The version of the bible-file - it's based on semantic versioning[^1]:

The first number indicates the layout-version of the file and is incremented whenever there are changes that are not backwards compatible.
The second number is incremented when the content gets (planned) changes.
The third number is incremented when bugs get fixed.

# Example
```json
{
"metadata": {
"caption": "Psalm x",
"id": "EG x",
"book": "Evangelisches Gesangsbuch",
"indent": true
},
"text": [
[
[
"first line of the first verse on the the first slide",
"second line of the first verse on the the first slide"
],
[
"first line of the second verse on the the first slide",
"second line of the second verse on the the first slide"
]
],
[
[
"first line of the thirds verse on the the second slide",
"second line of the thirds verse on the the second slide"
]
]
],
"version": "1.0.0"
}
```

[^1]: [https://semver.org](https://semver.org)

0 comments on commit c786e23

Please sign in to comment.