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 🙏

© 2026 – Pkg Stats / Ryan Hefner

displaycommitversion

v1.0.3

Published

Discord bot utility to display git commit version in bot bio

Readme

displaycommitversion

Discord 봇의 바이오(소개)에 현재 git 커밋 버전을 자동으로 표시해주는 유틸리티 패키지입니다.

설치

npm install displaycommitversion

함수

getCommitVersion(options?)

최신 git 커밋 정보를 가져옵니다.

| 파라미터 | 타입 | 기본값 | 설명 | | -------------------- | -------- | ------ | ----------------- | | options.dateFormat | string | "%h" | git log 날짜 포맷 |

반환값: 커밋 버전 문자열. git 실행 실패 시 "unknown" 반환.

import { getCommitVersion } from "displaycommitversion";

const version = getCommitVersion();
// 예: "2025-05-17 12:34:56 +0900"

const customVersion = getCommitVersion({ dateFormat: "%h" });
// 예: "a1b2c3d" (짧은 커밋 해시)

changeBotBio(client, bio, options?)

Discord 봇의 바이오를 커밋 버전 정보와 함께 업데이트합니다.

| 파라미터 | 타입 | 설명 | | -------------------------- | -------- | -------------------------------------------------------------- | | client | Client | discord.js Client 인스턴스 | | bio | string | 설정할 바이오 텍스트. {commitVersion} 플레이스홀더 사용 가능 | | options.commitDateOption | string | 커밋 버전의 날짜 포맷 (선택) |

반환값: Promise<boolean> — 성공 시 true, 실패 시 false.

import { Client, GatewayIntentBits } from "discord.js";
import { changeBotBio } from "displaycommitversion";

const client = new Client({ intents: [GatewayIntentBits.Guilds] });

client.once("ready", async () => {
  await changeBotBio(client, "My Bot | 배포: {commitVersion}");
  // 바이오가 "My Bot | 배포: 2025-05-17 12:34:56 +0900" 으로 업데이트됨
});

client.login("YOUR_BOT_TOKEN");

커밋 해시를 표시하고 싶다면:

await changeBotBio(client, "v1.0 | commit: {commitVersion}", {
  commitDateOption: "%h",
});
// 바이오가 "v1.0 | commit: a1b2c3d" 으로 업데이트됨

라이선스

ISC