Skip to content

Commit

Permalink
Merge pull request #20 from wit-ai/marketplace_preset_fix
Browse files Browse the repository at this point in the history
generate presets into game content folder for marketplace build
  • Loading branch information
wangpingsx authored Jan 3, 2023
2 parents 0ee6bd3 + 94efb42 commit 174f2e3
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions scripts/all-in-one/utils/all_in_one_packaging.bat
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ git clone https://github.com/wit-ai/voicesdk-unreal

echo ">> 3. add WITH_VOICESDK macro for 'create preset' feature, this can be removed if 2 repos merged."
node ../../utils/update_WITH_VOICESDK_flag.js
node ../../utils/update_WITH_VOICESDK_MARKETPLACE_flag.js
node ../../update_WITH_VOICESDK_USERAGENT_flag.js

echo ">> 4. Copy code and content from wit to voicesdk"
Expand Down
16 changes: 16 additions & 0 deletions scripts/all-in-one/utils/update_WITH_VOICESDK_MARKETPLACE_flag.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the license found in the
* LICENSE file in the root directory of this source tree.
*/

var fs = require('fs');
const updateFileAsync = require("../../helper");

const FILE_PATH = 'wit-unreal\\Source\\WitEditor\\WitEditor.Build.cs';
const KEY_STRING_START = 'PrivateDefinitions.Add("WITH_VOICESDK_MARKETPLACE=';
const KEY_STRING_END = '"';
const replacement = '1'

updateFileAsync(FILE_PATH, KEY_STRING_START, replacement, KEY_STRING_END);

0 comments on commit 174f2e3

Please sign in to comment.