Skip to content

Commit

Permalink
cant test the workflow if not on master, wtf
Browse files Browse the repository at this point in the history
  • Loading branch information
signorecello committed Oct 26, 2023
1 parent 38f27bc commit 0051bcc
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions docs/scripts/setStable.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
const fs = require('fs');
const path = require('path');

const process = require('process');
const console = require('console');

function main() {
const configFile = path.join('docusaurus.config.js');

Expand All @@ -13,8 +16,10 @@ function main() {
console.log('No stable version provided');
process.exit(1);
}
console.log(newVersion);
const updatedContent = configContent.replace(/lastVersion: '[^']+'/, `lastVersion: '${newVersion}'`);

console.log(updatedContent);
// Write the updated content back
fs.writeFileSync(configFile, updatedContent, 'utf8');
}
Expand Down

0 comments on commit 0051bcc

Please sign in to comment.