Skip to content

Commit

Permalink
fix: tendermint installation step
Browse files Browse the repository at this point in the history
  • Loading branch information
angrybayblade committed May 31, 2024
1 parent 4c1e96b commit 42e0a4f
Showing 1 changed file with 13 additions and 17 deletions.
30 changes: 13 additions & 17 deletions electron/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ async function installTendermintUnix() {

console.log(appendLog(`Downloading ${url}, might take a while...`))
await downloadFile(url, `${TempDir}/tendermint.tar.gz`)

console.log(appendLog(`Installing tendermint binary`))
await runCmdUnix("tar", ["-xvf", "tendermint.tar.gz"])
await runSudoUnix("install", "tendermint /usr/local/bin")
Expand Down Expand Up @@ -295,13 +295,6 @@ async function setupDarwin(ipcChannel) {
installBrew();
}

console.log(appendLog('Checking tendermint installation'));
if (!isTendermintInstalledUnix()) {
ipcChannel.send('response', 'Installing Pearl Daemon');
console.log(appendLog('Installing tendermint'));
await installTendermintUnix()
}

console.log(appendLog('Checking python installation'));
if (!isPythonInstalledDarwin()) {
ipcChannel.send('response', 'Installing Pearl Daemon');
Expand All @@ -313,6 +306,13 @@ async function setupDarwin(ipcChannel) {
await createDirectory(`${OperateDirectory}`);
await createDirectory(`${OperateDirectory}/temp`);

console.log(appendLog('Checking tendermint installation'));
if (!isTendermintInstalledUnix()) {
ipcChannel.send('response', 'Installing Pearl Daemon');
console.log(appendLog('Installing tendermint'));
await installTendermintUnix()
}

if (!fs.existsSync(VenvDir)) {
ipcChannel.send('response', 'Installing Pearl Daemon');
console.log(appendLog('Creating virtual environment'));
Expand Down Expand Up @@ -342,13 +342,6 @@ async function setupDarwin(ipcChannel) {
async function setupUbuntu(ipcChannel) {
removeInstallationLogFile();

console.log(appendLog('Checking tendermint installation'));
if (!isTendermintInstalledUnix()) {
ipcChannel.send('response', 'Installing Pearl Daemon');
console.log(appendLog('Installing tendermint'));
await installTendermintUnix()
}

console.log(appendLog('Checking python installation'));
if (!isPythonInstalledUbuntu()) {
ipcChannel.send('response', 'Installing Pearl Daemon');
Expand All @@ -367,8 +360,11 @@ async function setupUbuntu(ipcChannel) {
await createDirectory(`${OperateDirectory}`);
await createDirectory(`${OperateDirectory}/temp`);

if (versionBumpRequired()) {
writeVersion();
console.log(appendLog('Checking tendermint installation'));
if (!isTendermintInstalledUnix()) {
ipcChannel.send('response', 'Installing Pearl Daemon');
console.log(appendLog('Installing tendermint'));
await installTendermintUnix()
}

if (!fs.existsSync(VenvDir)) {
Expand Down

0 comments on commit 42e0a4f

Please sign in to comment.