Skip to main content

static binaries of npm and node

Project description

static-npm

Static version of npm so that you can install useful npm tools.

Linting

MacOS_Tests

Ubuntu_Tests

Win_Tests

Cmds

static-npm alias to npm static-node alias to node static-npx alias to npx

Api

from static_npm import Npm, Node, Npx
npm = Npm()
print(f"npm path: {npm.path}")
proc = npm.run(["--version"])
proc.wait()
assert "10.9.0" in proc.stdout

Examples

import unittest
from static_npm.npm import Npm

class MainTester(unittest.TestCase):
    """Main tester class."""

    def test_npm_run_version(self) -> None:
        """Test command line interface (CLI)."""
        npm = Npm()
        proc = npm.run(["--version"])
        rtn = proc.wait()
        version = proc.stdout
        print(f"Version: {version}")
        self.assertIn("10.9.0", version)
        self.assertEqual(0, rtn)
        self.assertEqual(npm.binaries.npm.exists(), True)


if __name__ == "__main__":
    unittest.main()

To develop software, run . ./activate.sh

Windows

This environment requires you to use git-bash.

Linting

Run ./lint.sh to find linting errors using pylint, flake8 and mypy.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

static_npm-1.0.0-py2.py3-none-any.whl (8.6 kB view details)

Uploaded Python 2Python 3

File details

Details for the file static_npm-1.0.0-py2.py3-none-any.whl.

File metadata

  • Download URL: static_npm-1.0.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 8.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.11.5

File hashes

Hashes for static_npm-1.0.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 717232a74822cf36af7ead2771f242c45e77599dc9d1188fdb6f8c1734cd4746
MD5 2bc0f00183945d620be3e966a2d997ec
BLAKE2b-256 63c6ba75376aebef845855cbacbbf14572ce5009766cd3722333b896fe39557a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page