npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

easier-deploy

v3.2.8

Published

make deployment easier

Downloads

4

Readme

easier-deploy 简易部署

通过指令实现自动化部署,压缩文件,上传文件到服务端,替换服务端文件,还能执行自定义脚本完成启动, 且支持分布式部署。

Usage 使用方法

安装依赖

npm i -D easier-deploy

在package.json中加入这个脚本

"script": {
    "deploy": "easier-deploy"
}

在终端输入这个指令

 npm run deploy [envkey] // eg: npm run deploy dev

如果你是第一次运行这个命令,它会在项目的根目录生成一个deploy.config.js文件。 然后你须修改这个文件去适配你的需求。

model.exports = {
	"context": './dist',
	"clean": false,
	"dev": [
		{
			"host": "10.0.0.1",
			"port": 22,
			"username": "admin",
			"password": "123456"
			"remotePath": "/home/admim/web/",
			"shell": "echo 'exec shell command success!!!'"
		}
	],
	[envKey]: []
}

你可以在终端上输入不同的环境键值去切换你的服务器配置,举个例子,你输入npm run dev 可以设置你的部署配置,然后就能把你的项目部署到dev服务器上。

deploy.config.js param 参数

|name|description|type|default value| |----|----|----|----| |context|项目的相对路径|string| null | |clean|清理服务器远端路径文件|boolean|false| |[envKey]|服务器配置|Array|[]|

[enKey] param 环境参数

|name|description|type|default value| |----|----|----|----| |host|服务器ip|string|null| |port|服务起ssh端口|number|null| |username|服务器用户名|string|null| |password|服务器密码|string|null| |privateKeyPath|私钥地址,选填|string|null| |privateKey|私钥键码,选填|string|null| |passphrase|私钥密码,选填|string|null| |remotePath|目标远端地址|string|null| |shell|部署完成后可执行的脚本|string|null|