Skip to content

Commit

Permalink
adds js support and minors
Browse files Browse the repository at this point in the history
  • Loading branch information
donadev committed Oct 15, 2024
1 parent 4b83429 commit 32ea343
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 4 deletions.
4 changes: 2 additions & 2 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ export const getOpenSimulatorId = async (platform: Platform) => {
* @returns A promise that resolves with a boolean indicating if the simulator is booted
*/
export const isSimulatorBooted = async (id: string, platform: Platform) => {
return cli(commands.isSimulatorBooted(id), platform)
return await cli(commands.isSimulatorBooted(id), platform) == "true"
}

/**
Expand Down Expand Up @@ -115,5 +115,5 @@ export const getAvailableSimulators = async (platform: Platform) => {
* @returns A promise that resolves with a boolean indicating if the app is installed
*/
export const isAppInstalled = async (appId: string, platform: Platform) => {
return cli(commands.isAppInstalled(appId), platform)
return await cli(commands.isAppInstalled(appId), platform) == "true"
}
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
{
"name": "udblib",
"version": "0.1.1",
"version": "0.1.4",
"description": "Universal Debug Bridge: Control your iOS Simulators and Android Emulators via cli",
"main": "index.js",
"scripts": {
"build": "tsc",
"test": "echo \"Error: no test specified\" && exit 1",
"postinstall": "brew install facebook/fb/idb-companion cliclick pipx && pipx install fb-idb"
},

"main": "dist/index.js",
"types": "dist/index.d.ts",
"repository": {
"type": "git",
"url": "git+https://github.com/donadev/udb.git"
Expand Down
15 changes: 15 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"lib": ["es2017", "es7", "es6", "dom"],
"declaration": true,
"outDir": "dist",
"strict": true,
"esModuleInterop": true
},
"exclude": [
"node_modules",
"dist"
]
}

0 comments on commit 32ea343

Please sign in to comment.