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

@varlinor/cli

v1.0.4

Published

This package provides a set of command-line tools for managing and building front-end projects. These tools include functionalities for cleaning the node_modules directory, creating and managing project versions, removing Git tags, and generating Vue comp

Downloads

8

Readme

@varlinor/cli

该包提供了一系列用于管理和构建前端项目的命令行工具。这些工具包括清理项目的node_modules目录、创建和管理项目版本、删除Git标签、以及生成Vue组件的定义文件和入口文件等功能。通过这些CLI工具,开发者可以更高效地维护项目结构,管理版本控制,自动化常见的开发任务,并简化组件的生成和管理流程。

This package provides a set of command-line tools for managing and building front-end projects. These tools include functionalities for cleaning the node_modules directory, creating and managing project versions, removing Git tags, and generating Vue component definition files and entry files. With these CLI tools, developers can more efficiently maintain project structure, manage version control, automate common development tasks, and simplify the generation and management of components.

Installation

npm install -D @varlinor/cli

// or

pnpm add -D @varlinor/cli

Usage

  1. clean命令

    • 功能: 用于清理指定模块的node_modules目录。可以指定目录和模块名称,或使用当前路径。
    • 选项:
      • -c, --current-path: 使用当前路径。
      • -b, --base-dir: 目标目录。
      • -m, --module-name <moduleName>: 模块名称。
    qkt-cli clean -b /path/to/base/dir -m moduleName

    或者使用当前路径:

    qkt-cli clean -c
  2. semver命令

    • 功能: 用于创建包版本,必须在项目根目录中运行。支持创建majorminorpatch版本,以及查看本地和远程的版本信息。
    • 选项:
      • -c, --create <createType>: 指定创建的版本类型(majorminorpatch)。
      • -i, --info: 打印当前版本信息。
      • -r, --remote: 打印远程版本信息。
      • -s, --snapshot <snapshotType>: 为不同分支指定快照类型。
      • -o, --output: 替换templates/package.json中的版本。

在项目根目录中运行以创建或查看包的版本信息。

qkt-cli semver -c minor

查看当前版本信息:

qkt-cli semver -i

查看远程版本信息:

qkt-cli semver -r

为不同的分支指定快照类型:

qkt-cli semver -s datacore

替换templates/package.json中的版本:

qkt-cli semver -o
  1. tag命令

    • 功能: 用于删除无用的Git标签,必须在项目根目录中运行。可以选择清除本地或远程的标签。
    • 选项:
      • -r, --remote: 清除远程标签。
      • -o, --remoteName <remoteName>: 指定要移除标签的远程名称。
      • -f, --filterCode <filterCode>: 用于过滤要删除的标签。

从本地和远程删除不需要的Git标签。

qkt-cli tag -f snapshot -r

指定远程名称:

qkt-cli tag -f snapshot -r -o origin
  1. generate define命令
    • 功能: 用于为包生成Vue组件的定义文件和入口文件。支持生成TypeScript或JavaScript的入口文件。
    • 选项:
      • -t, --isTs: 指定源文件为TypeScript。
      • -e, --isOutputEntry: 是否创建入口文件。

为包生成Vue组件的定义文件和入口文件。

qkt-cli generate define -t -e