Skip to content

Commit

Permalink
Update web launch scripts (#1298)
Browse files Browse the repository at this point in the history
  • Loading branch information
laves authored Aug 20, 2024
1 parent 1462f5c commit 9d1adfe
Show file tree
Hide file tree
Showing 12 changed files with 43 additions and 27 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/angular-demos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,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 @@ -20,11 +20,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
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"]["singleKeyword"].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 @@ -106,6 +106,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'
});
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
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 'PorcupineDemo' 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 @@ -14,7 +14,7 @@ PODS:
- ios-voice-processor (1.1.0)
- Porcupine-iOS (3.0.1):
- ios-voice-processor (~> 1.1.0)
- porcupine-react-native (3.0.1):
- porcupine-react-native (3.0.2):
- Porcupine-iOS (~> 3.0.1)
- React
- RCT-Folly (2021.06.28.00-v2):
Expand Down Expand Up @@ -224,7 +224,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 @@ -419,7 +419,7 @@ SPEC CHECKSUMS:
glog: 476ee3e89abb49e07f822b48323c51c57124b572
ios-voice-processor: 8e32d7f980a06d392d128ef1cd19cf6ddcaca3c1
Porcupine-iOS: 6d69509fa587f3ac0be1adfefb48e0c6ce029fff
porcupine-react-native: f6650a418ba767c210eeb416d4e0bdbb93a209ca
porcupine-react-native: 8d7374c0fea2fa6ad645139f33150290a56f574e
RCT-Folly: 4d8508a426467c48885f1151029bc15fa5d7b3b8
RCTRequired: 530916cd48c5f7cf1fc16966ad5ea01638ca4799
RCTTypeSafety: 5fb4cb3080efd582e5563c3e9a0e459fc51396c5
Expand All @@ -433,7 +433,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 @@ -449,6 +449,6 @@ SPEC CHECKSUMS:
RNCPicker: 0991c56da7815c0cf946d6f63cf920b25296e5f6
Yoga: 0bc4b37c3b8a345336ff601e2cf7d9704bab7e93

PODFILE CHECKSUM: 8921bb939d724a5ead76bd00f8a96af2bfb18432
PODFILE CHECKSUM: 0052e6a10d8424d84416b8090efd0354fc489666

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.singleKeyword.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-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"]["singleKeyword"].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 @@ -106,6 +106,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'
});
2 changes: 1 addition & 1 deletion demo/unity/images/image_attribution.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Icons made by [Freepik](https://www.freepik.com) from [Flaticon](https://www.flaticon.com/)
Icons made by [Freepik](https://www.freepik.com) from [Flaticon](https://www.flaticon.com/)<!-- markdown-link-check-disable-line -->
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"]["singleKeyword"].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 @@ -102,6 +102,7 @@ export default porcupineModel;

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 @@ -112,6 +112,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 9d1adfe

Please sign in to comment.