Skip to content

Commit

Permalink
Merge pull request #207 from bible-technology/develop
Browse files Browse the repository at this point in the history
Merge for SB 0.2.0-beta.2
  • Loading branch information
jag3773 authored Jul 9, 2020
2 parents b1ab146 + a94d808 commit e898180
Show file tree
Hide file tree
Showing 24 changed files with 1,407 additions and 1,228 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: CI
on: [ push ]

jobs:
ajv-test:
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
# Installs node
- uses: actions/setup-node@v1
with:
node-version: '12'
- run: npm install ajv
- run: node code/validate.js metadata docs/examples/artifacts/*.json
- run: node code/validate.js recipeSpec docs/examples/artifacts/ingredients/bits_of_burrito.recipe_spec.json
python-test:
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- run: pip3 install jsonschema
- run: python3 code/validate.py docs/examples/artifacts/*.json
25 changes: 25 additions & 0 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: npm-publish
on:
push:
branches:
- master # Change this to your default branch
jobs:
npm-publish:
name: npm-publish
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@master
- name: Set up Node.js
uses: actions/setup-node@master
with:
node-version: 12.x
- name: Publish if version has been updated
uses: pascalgn/npm-publish-action@4f4bf159e299f65d21cd1cbd96fc5d53228036df
with: # All of theses inputs are optional
tag_name: "v%s"
tag_message: "v%s"
commit_pattern: "^Release (\\S+)"
env: # More info about the environment variables in the README
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Leave this as is, it's automatically generated
NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} # You need to set this in your repo settings
10 changes: 8 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
node_modules
proto_doc/dbl_2_3/briefing_papers/DBLMetadata23.log
proto_doc/dbl_2_3/briefing_papers/SB01RFC.log

# build artifacts and language support
node_modules
**/_build
**/build
.DS_Store
.python-version

# IDE artifacts
.vscode
Expand All @@ -15,4 +18,7 @@ docs/schema/metadata.rng
# Emacs files
*~
\#*\#
.\#*
.\#*

# Mac OSX artifacts
.DS_Store
13 changes: 0 additions & 13 deletions .travis.yml

This file was deleted.

21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2020 BT Tech Consortium

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
21 changes: 15 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
[![Documentation Status](https://readthedocs.org/projects/scripture-burrito/badge/?version=latest)](https://docs.burrito.bible/en/latest/?badge=latest)
[![Build Status](https://travis-ci.org/bible-technology/scripture-burrito.svg?branch=master)](https://travis-ci.org/bible-technology/scripture-burrito)
master:[![Documentation Status](https://readthedocs.org/projects/scripture-burrito/badge/?version=latest)](https://docs.burrito.bible/en/latest/?badge=latest)
[![CI](https://github.com/bible-technology/scripture-burrito/workflows/CI/badge.svg?branch=master)](https://github.com/bible-technology/scripture-burrito/actions?query=branch%3Amaster)

develop:[![Documentation Status](https://readthedocs.org/projects/scripture-burrito/badge/?version=develop)](https://docs.burrito.bible/en/latest/?badge=develop)
[![CI](https://github.com/bible-technology/scripture-burrito/workflows/CI/badge.svg?branch=develop)](https://github.com/bible-technology/scripture-burrito/actions?query=branch%3Adevelop)

# Scripture Burrito Documentation

A data interchange format for Bible-centric content.

See https://docs.burrito.bible/ (or https://scripture-burrito.readthedocs.io/) for the documentation, this repo is the source files.

If you want to suggest a change, please fork this repo and create a PR, or create an Issue.
Expand Down Expand Up @@ -47,12 +51,17 @@ A similar script is used for the examples.

### Scripted

There is both a Python and JavaScript utility included in `code/` that validate JSON documents against the schema.
An [automated Github Action](https://github.com/bible-technology/scripture-burrito/blob/jag3773-patch-1/.github/workflows/main.yml) runs on each push that validates the metadata samples. This uses both a Python and JavaScript utility included in `code/` to validate JSON documents against the schema. You can run these locally as well.

The Python script requires `jsonschema` (run `pip install jsonschema`) and may be run as follows:
The Python script requires `jsonschema` (run `pip install jsonschema`) and may be run as follows:

python code/validate.py docs/examples/artifacts/*.json

The JavaScript script requires `node` and `ajv` to run.

npm install ajv
node code/validate.js metadata docs/examples/artifacts/*.json

### For Real Time Editing

The VS Code [documentation](https://code.visualstudio.com/docs/languages/json#_json-schemas-and-settings) explains how to setup VS Code for real time validation of JSON files using a schema.
Expand All @@ -72,7 +81,7 @@ In short, create a `.vscode/settings.json` file in your `scripture-burrito` work
}
```

Of course, use the actual local path on *your system* for `metadata.schema.json`.
Of course, use the actual local path on _your system_ for `metadata.schema.json`.

To test, open up `schema/scriptureText.json` and make something invalid, and see the result, like this:
![image](https://user-images.githubusercontent.com/194842/71215968-6ced3300-22b9-11ea-95a7-ca84de8287da.png)
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@
# built documents.
#
# The short X.Y version.
version = u'0.2.0-beta'
version = u'0.2.0-beta.2'
# The full version, including alpha/beta/rc tags.
release = u'0.2.0-beta'
release = u'0.2.0-beta.2'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
8 changes: 5 additions & 3 deletions docs/examples/artifacts/audioTranslation.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"meta": {
"version": "0.2.0",
"version": "0.2.0-beta.2",
"variant": "source",
"generator": {
"softwareName": "DBLImport",
Expand All @@ -9,7 +9,9 @@
},
"defaultLanguage": "en",
"dateCreated": "2018-03-15T19:38:40.762935+00:00",
"comments": ["Updated with working audio files for GEN 1-3 and MAT 1-3, test browser open on success"]
"comments": [
"Updated with working audio files for GEN 1-3 and MAT 1-3, test browser open on success"
]
},
"idServers": {
"dbl": {
Expand Down Expand Up @@ -50,7 +52,7 @@
"name": "scripture",
"flavor": {
"name": "audioTranslation",
"performance": ["multipleVoice", "drama", "withMusic"],
"performance": ["multipleVoice", "drama", "withMusic"],
"formats": {
"format1": {
"compression": "mp3",
Expand Down
Loading

0 comments on commit e898180

Please sign in to comment.