Skip to content

Commit

Permalink
Update web launch scripts (#724)
Browse files Browse the repository at this point in the history
  • Loading branch information
laves authored Aug 20, 2024
1 parent aad6db4 commit 2c699da
Show file tree
Hide file tree
Showing 15 changed files with 48 additions and 32 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/angular-demos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ defaults:

jobs:
build-demos:
runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}

strategy:
matrix:
node-version: [16.x, 18.x, 20.x]
os: [ ubuntu-latest, windows-latest, macos-latest ]
node-version: [ 16.x, 18.x, 20.x ]

steps:
- uses: actions/checkout@v3
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/react-demos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ defaults:

jobs:
build:
runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}

strategy:
matrix:
node-version: [16.x, 18.x, 20.x]
os: [ ubuntu-latest, windows-latest, macos-latest ]
node-version: [ 16.x, 18.x, 20.x ]

steps:
- uses: actions/checkout@v3
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/vue-demos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ defaults:

jobs:
build-demos:
runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}

strategy:
matrix:
node-version: [16.x, 18.x, 20.x]
os: [ ubuntu-latest, windows-latest, macos-latest ]
node-version: [ 16.x, 18.x, 20.x ]

steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion binding/angular/projects/rhino-angular/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@picovoice/rhino-angular",
"description": "Angular service for Rhino Web SDK",
"version": "3.0.3",
"version": "3.0.4",
"peerDependencies": {
"@angular/common": ">=13.0.0",
"@angular/core": ">=13.0.0",
Expand Down
2 changes: 1 addition & 1 deletion demo/angular/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"@angular/platform-browser": "^15.0.3",
"@angular/platform-browser-dynamic": "^15.0.3",
"@angular/router": "^15.0.3",
"@picovoice/rhino-angular": "~3.0.3",
"@picovoice/rhino-angular": "~3.0.4",
"@picovoice/web-voice-processor": "~4.0.8",
"rxjs": "~7.5.0",
"tslib": "^2.3.0",
Expand Down
7 changes: 4 additions & 3 deletions demo/angular/scripts/run_demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const availableLanguages = testData["tests"]["within_context"].map(
(x) => x["language"]
);

const commands = process.argv.slice(2, -1);
const args = process.argv.slice(2, -1);
const language = process.argv.slice(-1)[0];

if (!availableLanguages.includes(language)) {
Expand Down Expand Up @@ -96,6 +96,7 @@ fs.writeFileSync(

const command = (process.platform === "win32") ? "npx.cmd" : "npx";

child_process.fork("ng", commands, {
execPath: command,
child_process.execSync(`${command} ng ${args.join(" ")}`, {
shell: true,
stdio: 'inherit'
});
8 changes: 4 additions & 4 deletions demo/angular/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1634,10 +1634,10 @@
read-package-json-fast "^3.0.0"
which "^3.0.0"

"@picovoice/rhino-angular@~3.0.3":
version "3.0.3"
resolved "https://registry.yarnpkg.com/@picovoice/rhino-angular/-/rhino-angular-3.0.3.tgz#f15724a0e0c986e291ccd22b69342f92b8d0d236"
integrity sha512-Jjo9gs9Xz3oAu8wBIiJJ3DK4L9lBXlprF3aOp2p2TbO7Sq+VNkNZvnsDuRINbJcZHIHfhTnJQULpLpPwyN2YnQ==
"@picovoice/rhino-angular@~3.0.4":
version "3.0.4"
resolved "https://registry.yarnpkg.com/@picovoice/rhino-angular/-/rhino-angular-3.0.4.tgz#d900fa9ea10be3ea444c4c4bbc1abc01dbe98e4b"
integrity sha512-fAlYod9YzuQ1meYWsXcwQtbx7XgdZFyDL5OSbm5V9a51RqbvgIsJD8WsYgpz6d0EU/mGlM48ox44mjabdRACpg==
dependencies:
"@picovoice/rhino-web" "=3.0.3"
tslib "^2.3.0"
Expand Down
2 changes: 1 addition & 1 deletion demo/react-native/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ android.useAndroidX=true
android.enableJetifier=true

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.54.0
FLIPPER_VERSION=0.99.0
File renamed without changes.
8 changes: 8 additions & 0 deletions demo/react-native/ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,11 @@ target 'RhinoDemo' do
config = use_native_modules!
use_react_native!(:path => config["reactNativePath"])
end

post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= ['$(inherited)', '_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION']
end
end
end
10 changes: 5 additions & 5 deletions demo/react-native/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ PODS:
- React-jsinspector (0.68.7)
- React-logger (0.68.7):
- glog
- react-native-voice-processor (1.2.0):
- react-native-voice-processor (1.2.2):
- ios-voice-processor (~> 1.1.0)
- React-Core
- React-perflogger (0.68.7)
Expand Down Expand Up @@ -289,7 +289,7 @@ PODS:
- React-perflogger (= 0.68.7)
- Rhino-iOS (3.0.1):
- ios-voice-processor (~> 1.1.0)
- rhino-react-native (3.0.1):
- rhino-react-native (3.0.2):
- React
- Rhino-iOS (~> 3.0.1)
- Yoga (1.14.0)
Expand Down Expand Up @@ -426,7 +426,7 @@ SPEC CHECKSUMS:
React-jsiexecutor: 7c0bd030a84f2ec446fb104b7735af2f5ed11eea
React-jsinspector: cab4d37ebde480f84c79ac89568abbf76b916c3e
React-logger: b75b80500ea80457b2cf169427d66de986cdcb29
react-native-voice-processor: aefb0845641c7d67dd47e69606ba7ebb38aab5cd
react-native-voice-processor: 6f8e5236d1a370be02aa87da8e34aa26506678df
React-perflogger: 44436b315d757100a53dfb1ab6b77c58cb646d7d
React-RCTActionSheet: 1888a229684762c40cc96c7ff4716f809655dc09
React-RCTAnimation: f05da175751867521d14b02ab4d3994a7b96f131
Expand All @@ -440,9 +440,9 @@ SPEC CHECKSUMS:
React-runtimeexecutor: 18932e685b4893be88d1efc18f5f8ca1c9cd39d8
ReactCommon: 29bb6fad3242e30e9d049bc9d592736fa3da9e50
Rhino-iOS: 4eeb02b38696907b28dd6f5dfa3a8f25355554ca
rhino-react-native: 8ef93ffeb956ad0c4843dfe0391df92cb9d290a6
rhino-react-native: c81671ddc7ead256db11f7457261ee193ad0ebde
Yoga: 0bc4b37c3b8a345336ff601e2cf7d9704bab7e93

PODFILE CHECKSUM: 4a3e20843482474120910ccf2e84e1141d29ec02
PODFILE CHECKSUM: 1f2f3e2c6481d5b9704ddd5f28215adf880d4aca

COCOAPODS: 1.11.3
7 changes: 4 additions & 3 deletions demo/react-native/scripts/run_demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const testData = require('../../../resources/.test/test_data.json');

const availableLanguages = testData.tests.within_context.map((x) => x.language);

const commands = process.argv.slice(2, -1);
const args = process.argv.slice(2, -1);
const language = process.argv.slice(-1)[0];

if (!availableLanguages.includes(language)) {
Expand Down Expand Up @@ -92,6 +92,7 @@ fs.writeFileSync(

const command = process.platform === 'win32' ? 'npx.cmd' : 'npx';

child_process.fork('react-native', commands, {
execPath: command,
child_process.execSync(`${command} react-native ${args.join(' ')}`, {
shell: true,
stdio: 'inherit',
});
7 changes: 4 additions & 3 deletions demo/react/scripts/run_demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const availableLanguages = testData["tests"]["within_context"].map(
(x) => x["language"]
);

const commands = process.argv.slice(2, -1);
const args = process.argv.slice(2, -1);
const language = process.argv.slice(-1)[0];

if (!availableLanguages.includes(language)) {
Expand Down Expand Up @@ -95,6 +95,7 @@ fs.writeFileSync(

const command = (process.platform === "win32") ? "npx.cmd" : "npx";

child_process.fork("react-scripts", commands, {
execPath: command,
child_process.execSync(`${command} react-scripts ${args.join(" ")}`, {
shell: true,
stdio: 'inherit'
});
7 changes: 4 additions & 3 deletions demo/vue/scripts/run_demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const availableLanguages = testData["tests"]["within_context"].map(
(x) => x["language"]
);

const commands = process.argv.slice(2, -1);
const args = process.argv.slice(2, -1);
const language = process.argv.slice(-1)[0];

if (!availableLanguages.includes(language)) {
Expand Down Expand Up @@ -92,6 +92,7 @@ export default rhinoModel;

const command = (process.platform === "win32") ? "npx.cmd" : "npx";

child_process.fork("vite", commands, {
execPath: command,
child_process.execSync(`${command} vite ${args.join(" ")}`, {
shell: true,
stdio: 'inherit'
});
5 changes: 3 additions & 2 deletions demo/web/scripts/run_demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ fs.writeFileSync(

const command = (process.platform === "win32") ? "npx.cmd" : "npx";

child_process.fork("http-server", ["-a", "localhost", "-p", "5000"], {
execPath: command,
child_process.execSync(`${command} http-server -a localhost -p 5000`, {
shell: true,
stdio: 'inherit'
});

0 comments on commit 2c699da

Please sign in to comment.