Skip to content

Commit

Permalink
Use node protocol for node.js APIs
Browse files Browse the repository at this point in the history
  • Loading branch information
bjester committed Apr 4, 2024
1 parent b9cca90 commit ec46a67
Show file tree
Hide file tree
Showing 12 changed files with 23 additions and 23 deletions.
2 changes: 1 addition & 1 deletion packages/kolibri-tools/lib/alias_import_resolver.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
var path = require('path');
var path = require('node:path');
var resolve = require('resolve');
var coreAliases = require('./apiSpecExportTools').coreAliases();
var coreExternals = require('./apiSpecExportTools').coreExternals();
Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/apiSpecExportTools.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable */
const fs = require('fs');
const path = require('path');
const fs = require('node:fs');
const path = require('node:path');
const resolve = require('resolve');
const espree = require('espree');
const escodegen = require('escodegen');
Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/clean.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
var path = require('path');
var fs = require('fs');
var path = require('node:path');
var fs = require('node:fs');
var logging = require('./logging');

var deleteRecursive = function(p) {
Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/cli.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env node
const fs = require('fs');
const path = require('path');
const fs = require('node:fs');
const path = require('node:path');
const program = require('commander');
const checkVersion = require('check-node-version');
const ini = require('ini');
Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/compress.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const { constants, createGzip } = require('zlib');
const { pipeline } = require('stream');
const { constants, createGzip } = require('node:zlib');
const { pipeline } = require('node:stream');
const { createReadStream, createWriteStream } = require('fs');
const logger = require('./logging');

Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/ensureDist.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const fs = require('fs');
const path = require('path');
const fs = require('node:fs');
const path = require('node:path');

function ensureDist() {
fs.mkdirSync(path.resolve(__dirname, '../dist'), { recursive: true });
Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/lint.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const fs = require('fs');
const path = require('path');
const fs = require('node:fs');
const path = require('node:path');
const prettier = require('prettier');
const compiler = require('vue-template-compiler');
const ESLintCLIEngine = require('eslint').CLIEngine;
Expand Down
6 changes: 3 additions & 3 deletions packages/kolibri-tools/lib/read_webpack_json.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const fs = require('fs');
const execSync = require('child_process').execSync;
const path = require('path');
const fs = require('node:fs');
const execSync = require('node:child_process').execSync;
const path = require('node:path');
const temp = require('temp').track();

const webpack_json = path.resolve(path.dirname(__filename), './webpack_json.py');
Expand Down
4 changes: 2 additions & 2 deletions packages/kolibri-tools/lib/version.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const fs = require('fs');
const execSync = require('child_process').execSync;
const fs = require('node:fs');
const execSync = require('node:child_process').execSync;
const temp = require('temp').track();
const readlineSync = require('readline-sync');
const semver = require('semver');
Expand Down
2 changes: 1 addition & 1 deletion packages/kolibri-tools/lib/webpack.config.plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* to add test specific features.
*/

const path = require('path');
const path = require('node:path');
const webpack = require('webpack');
const { merge } = require('webpack-merge');
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
Expand Down
6 changes: 3 additions & 3 deletions packages/kolibri-tools/lib/webpackBundleTracker.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.

const path = require('path');
const fs = require('fs');
const crypto = require('crypto');
const path = require('node:path');
const fs = require('node:fs');
const crypto = require('node:crypto');

const defaults = require('lodash/defaults');
const assign = require('lodash/assign');
Expand Down
2 changes: 1 addition & 1 deletion packages/kolibri-tools/lib/webpackRtlPlugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// Vendored and simplified from https://github.com/romainberger/webpack-rtl-plugin/blob/master/src/index.js
const path = require('path');
const path = require('node:path');
const rtlcss = require('rtlcss');
const webpack = require('webpack');

Expand Down

0 comments on commit ec46a67

Please sign in to comment.