Skip to content

Commit

Permalink
Upgrade raxml-ng to v1.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
danieledler committed Feb 21, 2022
1 parent 5db8896 commit 208a98f
Show file tree
Hide file tree
Showing 3 changed files with 258 additions and 116 deletions.
28 changes: 14 additions & 14 deletions scripts/download-binaries.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,40 +4,40 @@ const download = require('download');

const osName = (() => {
switch (process.platform) {
case "darwin":
return "Mac";
case "win32":
return "Windows";
case 'darwin':
return 'Mac';
case 'win32':
return 'Windows';
default:
return "Linux";
return 'Linux';
}
})();

const binariesBaseDir = "https://github.com/AntonelliLab/raxmlGUI-binaries/releases/download/v21.10.04";
const binariesBaseDir =
'https://github.com/AntonelliLab/raxmlGUI-binaries/releases/download/v22.02.21';
const binariesUrl = `${binariesBaseDir}/${osName}.zip`;

const binPath = path.join(__dirname, "..", "static", "bin");
const raxmlNgPath = path.join(binPath, "raxml-ng");
const binPath = path.join(__dirname, '..', 'static', 'bin');
const raxmlNgPath = path.join(binPath, 'raxml-ng');

(async () => {
console.log("Check binaries...");
console.log('Check binaries...');
let exist = true;
try {
await fs.access(raxmlNgPath, );
await fs.access(raxmlNgPath);
} catch (_) {
exist = false;
}

if (exist) {
console.log("Binaries exist!");
console.log('Binaries exist!');
return;
}

console.log(`Binaries missing, downloading from '${binariesUrl}'...`);

await download(binariesUrl, binPath, {
await download(binariesUrl, binPath, {
extract: true,
});
console.log("Done!")

console.log('Done!');
})();
Loading

0 comments on commit 208a98f

Please sign in to comment.