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 🙏

© 2025 – Pkg Stats / Ryan Hefner

ik-miniprogram-ci

v1.0.26

Published

ik-miniprogram-ci 是小程序打包、预览、上传工具,目前支持头条小程序、快手小程序、微信小程序。

Readme

介绍

ik-miniprogram-ci 是小程序打包、预览、上传工具,目前支持头条小程序、快手小程序、微信小程序。

注意事项

使用 ci 工具前需准备:

1、头条开发者账号绑定邮箱

2、快手和微信需生成上传代码密钥

3、项目根目录创建.ci-config.js 配置文件

安装

npm i ik-miniprogram-ci -D

使用

预览并发送钉钉群:miniprogram-ci preview

上传代码:miniprogram-ci publish

.ci-config.js 配置说明

完整配置示例

module.exports = {
  // 环境列表
  env: ['dev', 'prod'],
  // 小程序列表
  mp: ['guazi'],
  // 平台列表
  platforms: ['mp-weixin', 'mp-toutiao', 'mp-kuaishou'],
  // 二维码上传地址
  uploadConfig: {
    hostname: 'upload.xizhihk.com',
    path: '/upload/image?sufix=png',
  },
  // 钉钉通知配置
  dingtalks: {
    'mp-weixin': {
      secret:
        'xxx', // 钉钉机器人密钥
      accessToken:
        'xxx', // 钉钉机器人accessToken
    },
    'mp-toutiao': {
      secret:
        'xxx', // 钉钉机器人密钥
      accessToken:
        'xxx', // 钉钉机器人accessToken
    },
    'mp-kuaishou': {
      secret:
        'xxx', // 钉钉机器人密钥
      accessToken:
        'xxx', // 钉钉机器人accessToken
    },
  },
  /**
   * 获取发布配置
   * @param {环境} env
   * @param {小程序} mp
   * @param {平台} platform
   * @returns publishConfig
   * {
   *    appid: 小程序appid
   *    buildPath: 构建产物位置
   *    privateKeyPath: 微信或快手privateKey的位置,需要管理员在开发者平台生成
   * }
   */
  resolvePublishConfig(env, mp, platform) {
    return {
    	appid: 小程序appid
     	buildPath: 构建产物位置
      privateKeyPath: 微信或快手privateKey的位置,需要管理员在开发者平台生成
    };
  },
  // 自定义钉钉通知消息
  resolveNotifyMsg({
    env,
    description,
    mp,
    platform,
    publishResult,
    url,
    name,
    branchName,
  }) {
    return {
      title: 'xxx',
      text: 'xxx',
    };
  },
};

特殊配置项说明

resolvePublishConfig

获取发布配置

回调参数

| 参数 | 说明 | | -------- | ------ | | env | 环境 | | mp | 小程序 | | platform | 平台 |

函数返回值

函数必须返回一个对象,该对象包含以下字段

| 字段 | 说明 | | -------------- | -------------------------------------------------------- | | appid | 小程序 appid | | buildPath | 构建产物位置 | | privateKeyPath | 微信或快手 privateKey 的位置,需要管理员在开发者平台生成 |

resolveNotifyMsg

自定义钉钉通知消息

回调参数

函数接受参数为一个对象,该对象有以下字段

| 字段 | 说明 | | ------------- | ---------------------------------------------------------------- | | env | 环境 | | mp | 小程序 | | platform | 平台 | | description | 用户在在命令行输入的描述 | | url | 二维码图片地址 | | publishResult | 发布结果对象,包含字段为 publishTime:String, expireTime: String | | name | 操作人 | | branchName | 分支名 |

函数返回值

函数必须返回一个对象,该对象包含以下字段

| 字段 | 说明 | | ----- | ----------------------------- | | title | 钉钉消息标题 | | text | 钉钉消息内容,格式为 markdown |