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

@wowazun/papu

v0.1.0

Published

push する前に腕立て伏せ (papu = push after a push-up)。スマホの加速度センサーで腕立てを検出し、CLI にカラフルな進捗バーを表示する。

Downloads

172

Readme

papu 💪

status: for fun novelty not production ready

papu = push after a push-up.

⚠️ This is a for-fun / novelty project — basically a joke that happens to work. Use it for laughs, not in serious workflows.

Do your push-ups before you git push. papu installs a git pre-push hook that blocks your push until you finish a set of push-ups. It detects reps from your phone's motion sensor and shows a colorful live progress bar in your terminal.

日本語版はこちら / Japanese README

How it works

git push
  └─ the git pre-push hook launches `papu gate`
       ├─ starts a local HTTPS + WebSocket server
       ├─ prints a QR code in the terminal
       ├─ scan it with your phone → allow DeviceMotion → stream acceleration
       ├─ put the phone in your pocket and do push-ups → the bar fills up
       └─ target reached → exit 0 (push proceeds) / aborted → exit 1 (push blocked)

Why HTTPS? Reading a phone's motion sensor (DeviceMotion) in the browser requires a secure context. Plain http to a LAN IP is treated as insecure, so papu serves over HTTPS with a self-signed certificate. The first time, your phone shows a certificate warning — tap through it to continue (both devices must be on the same Wi-Fi).

Requirements

  • Node.js >= 20
  • A phone with a motion sensor (iOS Safari / Android Chrome) on the same Wi-Fi as your computer

Install

npm install -g @wowazun/papu

The package is published under the @wowazun scope, but the command it installs is just papu.

Usage

Enable push-up enforcement in any git repository:

cd path/to/your-repo
papu install          # add the git pre-push hook
papu target 20        # reps required for this repo (optional, default 10)

Now git push in that repo requires push-ups. Remove it with papu uninstall.

  • The hook calls node and papu by absolute path, so it works without any project-local install.
  • The target is stored per repo in .papurc.json.
  • The certificate is cached in ~/.papu, so you only accept the warning once.

Commands

papu doctor                    # check environment and LAN IP
papu target 20                 # save the required reps (persisted)
papu target                    # show the current target
papu gate                      # start a gate using the saved target
papu gate --target 10          # override the target for this run
papu gate --target 10 --no-sound   # mute the PC-side beeps
papu gate --target 3 --simulate    # try it without a phone
papu lang                      # show current language
papu lang ja                   # switch messages to Japanese (default: English)

Language

Messages default to English. Switch with any of:

  • papu lang ja (persisted to .papurc.json)
  • --lang ja on any command
  • the PAPU_LANG environment variable

The phone page and its voice prompts follow the same language.

Configuration

Drop a .papurc.json in your repo to override defaults:

{
  "target": 10,
  "port": 4443,
  "threshold": 3.0,
  "refractoryMs": 700,
  "plankAngleDeg": 45,
  "calibrationMs": 1200
}

Start detection (posture-gated)

Detecting the start from "movement" alone is unreliable (getting into position also shakes the phone). Instead papu uses gravity direction to detect your posture and only counts reps once you are in a plank. Walking or inserting the phone while standing never counts, because the gravity direction doesn't change.

  1. Tap "start" on the phone → stay still while standing (records the baseline gravity direction)
  2. Getting into a plank tilts gravity ~90° → detected as the start of counting
  3. Reps are counted only during the plank. Standing up stops it automatically.

Since you can't watch the screen mid-push-up, the phone speaks the count ("start", "1, 2, 3…", "done") and vibrates on Android.

  • plankAngleDeg: how many degrees of tilt from standing counts as a plank (default 45°)
  • calibrationMs: how long to hold still to capture the standing baseline (default 1.2s)

Development

git clone https://github.com/wowazun/papu.git
cd papu
npm install
npm run build
npm link            # makes `papu` available on your PATH
npm test

Roadmap

  • --tunnel (ngrok / cloudflared) for a warning-free connection method
  • VSCode extension (a "Push (with push-ups)" command running gate → git push in a webview)
  • Calibration (gate --calibrate) to auto-tune thresholds
  • Scale reps to the number of commits being pushed

Security notes

papu is meant for a trusted home network. Keep in mind:

  • It runs a local HTTPS + WebSocket server on your LAN. The connection is not authenticated, so anyone on the same network could connect and send fake reps. Use it on a trusted Wi-Fi, not on public/guest networks.
  • It serves over HTTPS with a self-signed certificate (cached in ~/.papu), so your phone shows a certificate warning the first time.
  • papu install writes a git pre-push hook into the current repository. Remove it any time with papu uninstall.

Found a security issue? Please open an issue on GitHub.

Disclaimer

papu is a for-fun / novelty project built as a joke. It works, but it isn't meant for serious or production use. It is provided as is, with no warranty and no support guarantees, and is maintained on a best-effort basis. Have fun with it. 💪

License

MIT © wowazun