Comparing version 0.0.2 to 1.3.0
13
index.js
@@ -1,6 +0,7 @@ | ||
'use strict'; | ||
var os = require('os'); | ||
module.exports = function() { | ||
return os.type && os.type(); | ||
}; | ||
"use strict"; | ||
function __export(m) { | ||
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p]; | ||
} | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
__export(require("./which-os")); | ||
//# sourceMappingURL=index.js.map |
109
package.json
{ | ||
"name": "which-os", | ||
"version": "0.0.2", | ||
"description": "check on what os node is running", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "mocha" | ||
"author": "Florian Keller <github@floriankeller.de>", | ||
"bin": { | ||
"is-linux": "cli.js --is-linux", | ||
"is-macos": "cli.js --is-macos", | ||
"is-windows": "cli.js --is-windows", | ||
"which-os": "cli.js" | ||
}, | ||
"dependencies": { | ||
"commander": "5.0.0" | ||
}, | ||
"description": "Get informations about your OS", | ||
"devDependencies": { | ||
"@ffflorian/prettier-config": "0.0.6", | ||
"@ffflorian/semantic-release-config": "0.2.0", | ||
"@ffflorian/tslint-config": "0.7.1", | ||
"@semantic-release/changelog": "5.0.1", | ||
"@semantic-release/git": "9.0.0", | ||
"@types/jasmine": "3.5.10", | ||
"@types/node": "~12", | ||
"husky": "4.2.3", | ||
"jasmine": "3.5.0", | ||
"lint-staged": "10.1.2", | ||
"prettier": "2.0.4", | ||
"publish-flat": "1.4.0", | ||
"rimraf": "3.0.2", | ||
"semantic-release": "17.0.4", | ||
"ts-node": "8.8.2", | ||
"tslint": "6.1.1", | ||
"tslint-config-prettier": "1.18.0", | ||
"tslint-plugin-prettier": "2.3.0", | ||
"typescript": "3.8.3" | ||
}, | ||
"engines": { | ||
"node": ">=0.10.0" | ||
"node": ">= 10.9" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/skippednote/which-os.git" | ||
}, | ||
"files": [ | ||
"index.js" | ||
"cli.d.ts", | ||
"cli.js", | ||
"cli.js.map", | ||
"index.d.ts", | ||
"index.js", | ||
"index.js.map", | ||
"which-os.d.ts", | ||
"which-os.js", | ||
"which-os.js.map" | ||
], | ||
"keywords": [ | ||
"os" | ||
"cli", | ||
"operating system", | ||
"os", | ||
"typescript" | ||
], | ||
"author": "Bassam Ismail", | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/skippednote/which-os/issues" | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "lint-staged" | ||
} | ||
}, | ||
"homepage": "https://github.com/skippednote/which-os", | ||
"devDependencies": { | ||
"mocha": "~1.17.0" | ||
} | ||
"license": "GPL-3.0", | ||
"lint-staged": { | ||
"*.{json,md,yml}": [ | ||
"prettier --write", | ||
"git add" | ||
], | ||
"spec/**/*.ts": [ | ||
"tslint --project tsconfig.jasmine.json --fix" | ||
], | ||
"src/**/*.ts": [ | ||
"tslint --project tsconfig.json --fix" | ||
] | ||
}, | ||
"main": "index.js", | ||
"name": "which-os", | ||
"prettier": "@ffflorian/prettier-config", | ||
"repository": "https://github.com/ffflorian/which-os.git", | ||
"release": { | ||
"extends": "@ffflorian/semantic-release-config" | ||
}, | ||
"scripts": { | ||
"build": "tsc", | ||
"clean": "rimraf dist", | ||
"dist": "yarn clean && yarn build", | ||
"fix": "yarn fix:other && yarn fix:ts", | ||
"fix:other": "yarn prettier --write", | ||
"fix:ts": "yarn lint:ts --fix && yarn lint:ts:spec --fix", | ||
"flatten": "publish-flat -o flattened", | ||
"lint": "yarn lint:ts && yarn lint:ts:spec && yarn lint:other", | ||
"lint:other": "yarn prettier --list-different", | ||
"lint:ts": "tslint --project tsconfig.json", | ||
"lint:ts:spec": "tslint --project tsconfig.jasmine.json", | ||
"postversion": "node ../node_modules/publish-flat/cli-copy.js -i package.json -o ../package.json version", | ||
"prettier": "prettier \"*.{json,md,yml}\"", | ||
"release": "semantic-release", | ||
"start": "ts-node src/cli.ts", | ||
"test": "ts-node -P tsconfig.jasmine.json node_modules/.bin/jasmine" | ||
}, | ||
"version": "1.3.0" | ||
} |
@@ -1,11 +0,29 @@ | ||
# which-os [![Build Status](https://travis-ci.org/skippednote/which-os.png?branch=master)](https://travis-ci.org/skippednote/which-os) | ||
> Tell me the OS | ||
# which-os [![Build Status](https://github.com/ffflorian/which-os/workflows/Build/badge.svg)](https://github.com/ffflorian/which-os/actions/) [![npm version](https://img.shields.io/npm/v/which-os.svg?style=flat)](https://www.npmjs.com/package/which-os) [![Dependabot Status](https://api.dependabot.com/badges/status?host=github&repo=ffflorian/which-os)](https://dependabot.com) | ||
### Example | ||
$ sudo node index.js | ||
Get informations about your OS | ||
// require which-os | ||
var whichOs = require('which-os'); | ||
## Usage | ||
whichOs(); | ||
//=> Linux/Window_NT/OSX | ||
Just run `npx which-os`. | ||
``` | ||
Usage: which-os [options] | ||
Get informations about your OS | ||
Options: | ||
--is-linux Is the operating system Linux? | ||
--is-macos Is the operating system macOS? | ||
--is-windows Is the operating system Windows? | ||
--is-x64 Is the processor architecture x64? | ||
--is-ia32 Is the processor architecture ia32? | ||
--is-arm Is the processor architecture ARM? | ||
-i, --os-info Output all OS informations | ||
-V, --verbose Enable verbose output | ||
-v, --version output the version number | ||
-h, --help output usage information | ||
``` | ||
## TypeScript Usage | ||
See [`./src/cli.ts`](./src/cli.ts) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Copyleft License
License(Experimental) Copyleft license information was found.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
Non-permissive License
License(Experimental) A license not known to be considered permissive was found.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Trivial Package
Supply chain riskPackages less than 10 lines of code are easily copied into your own project and may not warrant the additional supply chain risk of an external dependency.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
48813
13
168
1
30
1
19
2
70
2
2
+ Addedcommander@5.0.0
+ Addedcommander@5.0.0(transitive)