🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
DemoInstallSign in
Socket

dotnet-run

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dotnet-run - npm Package Compare versions

Comparing version

to
2.0.0-beta.0

35

index.js

@@ -1,34 +0,9 @@

const fs = require('fs');
const path = require('path');
const {spawn} = require('child_process');
const { spawn } = require("child_process")
module.exports = (filename, args, callback) => {
const options = {stdio: 'inherit'};
if (filename)
args.unshift(filename)
if (path.sep == '\\')
spawn(filename, args, options).on('exit', callback);
else {
if (filename)
args.unshift(filename);
const home = process.env.DOTNET_RUN_HOME ||
path.join(process.env.HOME, '.dotnet-run');
const mono = path.join(home, '.bin', 'mono');
if (fs.existsSync(mono))
spawn(mono, args, options).on('exit', callback);
else {
// Fallback to install script.
spawn('bash', [
path.join(__dirname, 'src', 'install.bash')
], {
stdio: 'inherit'
}).on('exit', code => {
if (code == 0)
spawn(mono, args, options).on('exit', callback);
else if (callback)
callback(code)
});
}
}
spawn("dotnet", args, { stdio: "inherit" })
.on("exit", callback)
}

9

package.json
{
"name": "dotnet-run",
"version": "1.5.0",
"version": "2.0.0-beta.0",
"description": "Run Mono and .NET programs easily on all platforms.",

@@ -9,3 +9,2 @@ "bin": {

"scripts": {
"install": "node src/install.js",
"test": "node test/test.js"

@@ -15,3 +14,2 @@ },

"bin/*",
"src/*",
"index.js"

@@ -24,6 +22,5 @@ ],

"keywords": [
"mono",
"cross-platform",
"dotnet",
"cross-platform",
"installer"
"helper"
],

@@ -30,0 +27,0 @@ "author": "Morten Daniel Fornes",

# dotnet-run
[![AppVeyor build status](https://img.shields.io/appveyor/ci/mortend/dotnet-run/master.svg?logo=appveyor&logoColor=silver&style=flat-square)](https://ci.appveyor.com/project/mortend/dotnet-run/branch/master)
[![Travis CI build status](https://img.shields.io/travis/mortend/dotnet-run/master.svg?style=flat-square)](https://travis-ci.org/mortend/dotnet-run)
[![NPM package](https://img.shields.io/npm/v/dotnet-run.svg?style=flat-square)](https://www.npmjs.com/package/dotnet-run)

@@ -10,3 +9,3 @@ [![NPM downloads](https://img.shields.io/npm/dt/dotnet-run?color=blue&style=flat-square)](https://www.npmjs.com/package/dotnet-run)

> Run Mono and .NET programs easily on all platforms.
> Run .NET programs easily on all platforms

@@ -18,29 +17,2 @@ ## Install

```
This will detect [Mono](https://www.mono-project.com/)/.NET or automatically download a suitable version for your system.
### macOS
![install](https://img.shields.io/badge/install-auto-brightgreen?style=flat-square&logo=apple&logoColor=silver)
![mono](https://img.shields.io/badge/mono-v6.0.0.311-blue?style=flat-square)
![downloads](https://img.shields.io/github/downloads/mortend/dotnet-run/total?color=blue&style=flat-square)
Unless we can find Mono v6.0.0.311 or greater on your system, we will provide you a minimal Mono installation automatically.
> We provide minimal Mono releases for macOS, much smaller than official releases. Our v6.0.0.311 is distributed as a 33.6 MB tarball, which installs faster and is more than ten times smaller than the official pkg installer at 362.2 MB. Our package is unobtrusive to your system and will safely co-exist with any existing Mono install you may or may not have from before.
### Linux
![install](https://img.shields.io/badge/install-manual-orange?style=flat-square&logo=linux&logoColor=silver)
![mono](https://img.shields.io/badge/mono-v6.0.0.311-blue?style=flat-square)
Linux users must provide their own Mono install before consuming this package. More information can be found on [this page](https://www.mono-project.com/download/).
### Windows
![install](https://img.shields.io/badge/install-auto-brightgreen?style=flat-square&logo=windows&logoColor=silver)
![install](https://img.shields.io/badge/netfx-built--in-blue?style=flat-square)
We use the built-in .NET Framework on Windows.
## Usage

@@ -53,3 +25,3 @@

run('bang.exe', ['pong', 'pang'], process.exit);
run('hello.dll', ['javascript', 'typescript'], process.exit);
```

@@ -60,26 +32,9 @@

```
$ dotnet-run bang.exe pong pang
$ dotnet-run hello.dll javascript typescript
Hello, pong pang!
Hello, javascript and typescript!
```
```
$ dotnet-run --version
Mono JIT compiler version 6.0.0.311 (2019-02/494641b300c Mon Jul 1 20:30:26 EDT 2019)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
TLS:
SIGSEGV: altstack
Notification: kqueue
Architecture: amd64
Disabled: none
Misc: softdebug
Interpreter: yes
LLVM: yes(600)
Suspend: hybrid
GC: sgen (concurrent by default)
```
## Contributing
Please [report an issue](https://github.com/mortend/dotnet-run/issues) if you encounter a problem, or [open a pull request](https://github.com/mortend/dotnet-run/pulls) if you make a patch.

Sorry, the diff of this file is not supported yet