Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixing mac install #100

Merged
merged 7 commits into from
Dec 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion doppler/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
edition = "2021"
name = "doppler"
version = "0.3.5"
version = "0.3.6"
repository = "https://github.com/tee8z/doppler.git"

[package.metadata.dist]
Expand Down
18 changes: 11 additions & 7 deletions doppler_ui/dist.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//used in build process please do not touch
const { bin } = require('./package.json');
const execSync = require('child_process').execSync;
const os = require('os');
const path = require('path');
const fs = require('fs');
const crypto = require('crypto');
Expand Down Expand Up @@ -53,14 +54,17 @@ if (!bunTarget) {
throw `To the best of our knowledge, bun does not support building for ${distTarget}`;
}
const binExt = distTarget.includes('windows') ? '.exe' : '';
const isDarwin = distTarget.includes('apple-darwin');
// Existing build process...
const isDarwin = process.platform === 'darwin';

if (isDarwin) {
console.log('Darwin detected. Installing @rollup/rollup-darwin-x64...');
execSync('npm install @rollup/rollup-darwin-x64', { stdio: 'inherit' });
console.log('Removing old installed dependencies ...');
execSync('rm package-lock.json', { stdio: 'inherit' });
execSync('rm -rf node_modules', { stdio: 'inherit' });
console.log('Darwin platform detected. Installing required dependencies...');
try {
console.log('Installing @rollup/rollup-darwin-x64...');
execSync('npm install --save @rollup/rollup-darwin-x64', { stdio: 'inherit' });
} catch (error) {
console.error('Error during Darwin setup:', error);
process.exit(1);
}
}

// Setup npm
Expand Down
Loading