Skip to content

Commit

Permalink
added pre-release resources to resource bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
PhotoNomad0 committed Sep 5, 2024
1 parent b138114 commit b427863
Show file tree
Hide file tree
Showing 35 changed files with 15,178 additions and 9 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"overwrite-resources": "rm -rf tcResources/en/bibles tcResources/en/translationHelps tcResources/el-x-koine tcResources/hi && npm run update-resources",
"update-apps": "git submodule foreach --recursive git checkout develop && git submodule foreach --recursive git pull",
"update-attributions": "node scripts/attributions/generateAttributionData.js src/js/components/home/license/attributionData.json",
"update-resources": "node scripts/resources/updateResources.js tcResources en hi el-x-koine hbo --allAlignedBibles --uWoriginalLanguage --unfoldingWordOrg",
"update-resources": "node scripts/resources/updateResources.js tcResources en hi el-x-koine hbo --allAlignedBibles --uWoriginalLanguage --unfoldingWordOrg --preProd",
"update-version": "node ./scripts/versionScript.js"
},
"repository": {
Expand Down
7 changes: 7 additions & 0 deletions scripts/resources/updateResources.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ const {
default: SourceContentUpdater,
apiHelpers,
resourcesHelpers,
STAGE,
} = require('tc-source-content-updater');
const packagefile = require('../../package.json');
const UpdateResourcesHelpers = require('./updateResourcesHelpers');
Expand All @@ -29,6 +30,7 @@ const TN_PATH = 'translationHelps/translationNotes';

let okToZip = false;
let unfoldingWordOrg = false
let preProd = false

/**
* remove load-after resources from updateList so no duplicate fetches
Expand Down Expand Up @@ -93,6 +95,10 @@ const updateResources = async (languages, resourcesPath, allAlignedBibles, uWori
latestManifestKey,
};

if (preProd) {
config.stage = STAGE.PRE_PROD
}

okToZip = true;

await sourceContentUpdater.getLatestResources(localResourceList, config)
Expand Down Expand Up @@ -755,6 +761,7 @@ if (require.main === module) {
const allAlignedBibles = findFlag(flags, '--allAlignedBibles'); // include all aligned bibles in package
const uWoriginalLanguage = findFlag(flags, '--uWoriginalLanguage'); // include original language resources from unfoldingWord org
unfoldingWordOrg = findFlag(flags, '--unfoldingWordOrg'); // include all resources from unfoldingWord org
preProd = findFlag(flags, '--preProd'); // include pre-release resources

if (! fs.existsSync(resourcesPath)) {
console.error('Directory does not exist: ' + resourcesPath);
Expand Down
2 changes: 1 addition & 1 deletion src/js/helpers/ProjectValidation/MissingVersesHelpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ export const getMissingVerses = (projectDir, bookAbbr, expectedVerses) => {
*/
export function findMissingVerses(usfmFilePath, bookAbbr) {
let expectedBookVerses = getExpectedBookVerses(bookAbbr);
return getMissingVerses(usfmFilePath, bookAbbr, expectedBookVerses);
return expectedBookVerses ? getMissingVerses(usfmFilePath, bookAbbr, expectedBookVerses) : {};
}

/**
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,56 @@
"bible-ot"
]
},
{
"title": "Leviticus",
"versification": "ufw",
"identifier": "lev",
"sort": 3,
"path": "./twl_LEV.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Numbers",
"versification": "ufw",
"identifier": "num",
"sort": 4,
"path": "./twl_NUM.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Deuteronomy",
"versification": "ufw",
"identifier": "deu",
"sort": 5,
"path": "./twl_DEU.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Joshua",
"versification": "ufw",
"identifier": "jos",
"sort": 6,
"path": "./twl_JOS.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Judges",
"versification": "ufw",
"identifier": "jdg",
"sort": 7,
"path": "./twl_JDG.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Ruth",
"versification": "ufw",
Expand All @@ -75,6 +125,66 @@
"bible-ot"
]
},
{
"title": "1 Samuel",
"versification": "ufw",
"identifier": "1sa",
"sort": 9,
"path": "./twl_1SA.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "2 Samuel",
"versification": "ufw",
"identifier": "2sa",
"sort": 10,
"path": "./twl_2SA.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "1 Kings",
"versification": "ufw",
"identifier": "1ki",
"sort": 11,
"path": "./twl_1KI.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "2 Kings",
"versification": "ufw",
"identifier": "2ki",
"sort": 12,
"path": "./twl_2KI.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "1 Chronicles",
"versification": "ufw",
"identifier": "1ch",
"sort": 13,
"path": "./twl_1CH.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "2 Chronicles",
"versification": "ufw",
"identifier": "2ch",
"sort": 14,
"path": "./twl_2CH.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Ezra",
"versification": "ufw",
Expand Down Expand Up @@ -115,6 +225,16 @@
"bible-ot"
]
},
{
"title": "Psalms",
"versification": "ufw",
"identifier": "psa",
"sort": 19,
"path": "./twl_PSA.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Proverbs",
"versification": "ufw",
Expand All @@ -125,6 +245,16 @@
"bible-ot"
]
},
{
"title": "Ecclesiastes",
"versification": "ufw",
"identifier": "ecc",
"sort": 21,
"path": "./twl_ECC.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Song of Solomon",
"versification": "ufw",
Expand All @@ -135,6 +265,86 @@
"bible-ot"
]
},
{
"title": "Isaiah",
"versification": "ufw",
"identifier": "isa",
"sort": 23,
"path": "./twl_ISA.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Jeremiah",
"versification": "ufw",
"identifier": "jer",
"sort": 24,
"path": "./twl_JER.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Lamentations",
"versification": "ufw",
"identifier": "lam",
"sort": 25,
"path": "./twl_LAM.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Ezekiel",
"versification": "ufw",
"identifier": "ezk",
"sort": 26,
"path": "./twl_EZK.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Daniel",
"versification": "ufw",
"identifier": "dan",
"sort": 27,
"path": "./twl_DAN.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Hosea",
"versification": "ufw",
"identifier": "hos",
"sort": 28,
"path": "./twl_HOS.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Joel",
"versification": "ufw",
"identifier": "jol",
"sort": 29,
"path": "./twl_JOL.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Amos",
"versification": "ufw",
"identifier": "amo",
"sort": 30,
"path": "./twl_AMO.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Obadiah",
"versification": "ufw",
Expand All @@ -155,6 +365,36 @@
"bible-ot"
]
},
{
"title": "Micah",
"versification": "ufw",
"identifier": "mic",
"sort": 33,
"path": "./twl_MIC.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Nahum",
"versification": "ufw",
"identifier": "nam",
"sort": 34,
"path": "./twl_NAM.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Habakkuk",
"versification": "ufw",
"identifier": "hab",
"sort": 35,
"path": "./twl_HAB.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Zephaniah",
"versification": "ufw",
Expand All @@ -175,6 +415,26 @@
"bible-ot"
]
},
{
"title": "Zechariah",
"versification": "ufw",
"identifier": "zec",
"sort": 38,
"path": "./twl_ZEC.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Malachi",
"versification": "ufw",
"identifier": "mal",
"sort": 39,
"path": "./twl_MAL.tsv",
"categories": [
"bible-ot"
]
},
{
"title": "Matthew",
"versification": "ufw",
Expand Down Expand Up @@ -446,7 +706,8 @@
]
}
],
"version": "84",
"catalog_modified_time": "2024-08-14T22:43:25Z",
"modifiedTime": "2024-08-14T22:43:25Z"
"version": "84.1",
"catalog_modified_time": "2024-08-15T16:21:53Z",
"modifiedTime": "2024-08-15T16:21:53Z",
"stage": "preprod"
}
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit b427863

Please sign in to comment.