Socket
Socket
Sign inDemoInstall

pake-cli

Package Overview
Dependencies
Maintainers
1
Versions
98
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pake-cli - npm Package Compare versions

Comparing version 0.0.1-beta.12 to 0.0.1-beta.13

12

bin/builders/MacBuilder.ts

@@ -11,2 +11,3 @@ import fs from 'fs/promises';

import { dir } from 'tmp-promise';
import { packageDirectory } from 'pkg-dir';

@@ -59,10 +60,13 @@ export default class MacBuilder implements IBuilder {

const code = await shellExec('../node_modules/@tauri-apps/cli/tauri.js build --config ${configJsonPath} --target universal-apple-darwin');
const npmDirectory = await packageDirectory();
console.log(npmDirectory)
const code = await shellExec(`${path.join(npmDirectory, 'node_modules/@tauri-apps/cli/tauri.js')} build --config ${configJsonPath} --target universal-apple-darwin`);
const dmgName = `${name}_${'0.2.0'}_universal.dmg`;
await fs.copyFile(this.getBuildedAppPath(dmgName), path.resolve(dmgName));
const appPath = this.getBuildedAppPath(npmDirectory, dmgName);
await fs.copyFile(appPath, path.resolve(dmgName));
}
getBuildedAppPath(dmgName: string) {
return `../src-tauri/target/universal-apple-darwin/release/bundle/dmg/${dmgName}`
getBuildedAppPath(npmDirectory: string, dmgName: string) {
return path.join(appRootPath.path, 'src-tauri/target/universal-apple-darwin/release/bundle/dmg', dmgName);
}
}

@@ -17,2 +17,4 @@ import * as Commander from 'commander';

import shelljs from 'shelljs';
import appRootPath from 'app-root-path';
import { packageDirectory } from 'pkg-dir';

@@ -363,9 +365,12 @@ /******************************************************************************

yield fs.writeFile(configJsonPath, Buffer.from(JSON.stringify(tauriConf), 'utf-8'));
yield shellExec('../node_modules/@tauri-apps/cli/tauri.js build --config ${configJsonPath} --target universal-apple-darwin');
const npmDirectory = yield packageDirectory();
console.log(npmDirectory);
yield shellExec(`${path.join(npmDirectory, 'node_modules/@tauri-apps/cli/tauri.js')} build --config ${configJsonPath} --target universal-apple-darwin`);
const dmgName = `${name}_${'0.2.0'}_universal.dmg`;
yield fs.copyFile(this.getBuildedAppPath(dmgName), path.resolve(dmgName));
const appPath = this.getBuildedAppPath(npmDirectory, dmgName);
yield fs.copyFile(appPath, path.resolve(dmgName));
});
}
getBuildedAppPath(dmgName) {
return `../src-tauri/target/universal-apple-darwin/release/bundle/dmg/${dmgName}`;
getBuildedAppPath(npmDirectory, dmgName) {
return path.join(appRootPath.path, 'src-tauri/target/universal-apple-darwin/release/bundle/dmg', dmgName);
}

@@ -372,0 +377,0 @@ }

{
"name": "pake-cli",
"version": "0.0.1-beta.12",
"version": "0.0.1-beta.13",
"description": "用 Rust 来打包你的 App,底层使用 Tauri,当前支持微信读书、Flomo、Vercel",

@@ -37,2 +37,3 @@ "bin": {

"page-icon": "^0.4.0",
"pkg-dir": "^7.0.0",
"png2icons": "^2.0.1",

@@ -39,0 +40,0 @@ "prompts": "^2.4.2",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc