New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

bun-repl

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bun-repl - npm Package Compare versions

Comparing version 1.2.1 to 1.3.0

23

package.json
{
"type": "module",
"name": "bun-repl",
"version": "1.2.1",
"version": "1.3.0",
"description": "Experimental unofficial REPL for Bun",
"main": "src/module/repl.ts",
"scripts": {
"start": "bun run src/repl.ts --",
"start": "bun run src/repl.ts",
"test": "bun run --silent check && bun run --silent start",

@@ -27,3 +27,3 @@ "deeptest": "bun run --silent lint && bun run --silent test",

"dependencies": {
"@swc/core": "^1.3.1",
"@swc/core": "^1.3.9",
"pretty-ms": "^8.0.0",

@@ -33,13 +33,12 @@ "rustybun": "^0.1.2"

"devDependencies": {
"@typescript-eslint/eslint-plugin": "^5.37.0",
"@typescript-eslint/parser": "^5.37.0",
"bun-types": "^0.1.11",
"eslint": "^8.23.1",
"eslint-plugin-unicorn": "^43.0.2",
"typescript": "^4.8.3"
"@typescript-eslint/eslint-plugin": "^5.40.1",
"@typescript-eslint/parser": "^5.40.1",
"bun-types": "^0.2.1",
"eslint": "^8.25.0",
"eslint-plugin-unicorn": "^44.0.2",
"typescript": "^4.8.4"
},
"bin": {
"repl": "./bun-repl-cli.sh",
"bun-repl": "./bun-repl-cli2.sh"
"bun-repl": "./src/repl.ts"
}
}
}

@@ -8,6 +8,7 @@ # bun-repl [![GitHub version][github-image]][github-url] [![GitHub code size in bytes][size-image]][github-url] [![license][license-image]][license-url]

## Install
```
`bun-repl` is not a local package, it **MUST** be installed globally to function properly!
```sh
bun add -g bun-repl
# alternatively now supports your package manager of choice (although only npm has been tested)
```
> ⚠️ Due to workarounds for Bun-specific issues, installation on other package managers like `npm` or `yarn` will not work.

@@ -14,0 +15,0 @@ ## Features

@@ -84,6 +84,15 @@ import repl from './module/repl';

ShadowRealm.prototype.execFile = async function (filepath) {
try { await this.importValue(filepath, ''); } catch (err) {
if ((<Error>err).message.trim() !== '%ShadowRealm%.importValue requires |exportName| to exist in the |specifier|')
throw err; // Unexpected error should not be suppressed.
ShadowRealm.prototype.execFile = async function(filepath) {
try {
filepath = Bun.resolveSync(filepath, import.meta.dir);
await this.importValue(filepath, '');
} catch (err) {
if ((<Error>err).message.trim() !== '%ShadowRealm%.importValue requires |exportName| to exist in the |specifier|') {
const error = new Error(
`%ShadowRealm%.execFile failed to execute file at ${filepath}` +
`\n(cause) ${(<Error>err).message}`
);
error.name = 'ShadowRealmExecFileError';
throw error; // Unexpected error should not be suppressed.
}
}

@@ -90,0 +99,0 @@ };

@@ -16,2 +16,5 @@ #!/usr/bin/env bun

// Futureproofing against addition or removal of the v prefix in the provided version
const BUN_VERSION = Bun.version[0] === 'v' ? Bun.version : 'v' + Bun.version;
const helpFlag = process.argv.includes('-h') || process.argv.includes('--help');

@@ -75,7 +78,7 @@ if (helpFlag) {

// Prepare realm environment
await realm.execFile('./realm.mjs');
await realm.execFile('./realm');
if (!singleshot) {
console.log(
`Welcome to Bun.js ${process.version}\n` +
`Welcome to Bun.js ${BUN_VERSION}\n` +
`Type ".help" for more information.`

@@ -182,3 +185,3 @@ );

Installed at: ${$.cyan+path.join(import.meta.dir, '..')+$.reset}
Bun version: ${process.version} ${$.dim}(${process.revision})${$.reset}
Bun version: ${BUN_VERSION} ${$.dim}(${Bun.revision})${$.reset}
SWC version: v${swc.version as string}

@@ -185,0 +188,0 @@ Color mode: ${$.bool(Bun.enableANSIColors)}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc