vibe-notify 0.2.1 → 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -91,7 +91,7 @@ Replace `"npx", "-y", "vibe-notify"` with `"vibe-notify"` if installed globally.
91
91
  ## CLI Reference
92
92
 
93
93
  ```
94
- vibe-notify [options] [sound-name]
94
+ vibe-notify [options] [sound-name | file-path]
95
95
 
96
96
  Options:
97
97
  --help, -h Show help
@@ -99,6 +99,9 @@ Options:
99
99
  --config, -c Print config file path
100
100
  --init Create default config file
101
101
  --version, -v Show version
102
+
103
+ You can also pass a path to a .wav/.mp3 file directly:
104
+ vibe-notify "C:\my-sounds\alert.wav"
102
105
  ```
103
106
 
104
107
  ## How It Works
package/dist/index.js CHANGED
@@ -42,6 +42,17 @@ async function main() {
42
42
  // ── Play sound ───────────────────────────────────────────────────────
43
43
  const config = (0, config_1.loadConfig)();
44
44
  const soundName = cli.soundName || config.sound;
45
+ // If the argument is a path to an existing file, play it directly
46
+ if (soundName && (0, fs_1.existsSync)(soundName)) {
47
+ try {
48
+ await (0, player_1.playFile)(soundName, config.playback.method);
49
+ }
50
+ catch (err) {
51
+ console.error(`Failed to play file: ${err.message}`);
52
+ process.exit(1);
53
+ }
54
+ return;
55
+ }
45
56
  // Validate sound name
46
57
  if (soundName !== 'custom' && !(0, beep_1.getPatternByName)(soundName)) {
47
58
  console.error(`Unknown sound: "${soundName}"`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibe-notify",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Notification sounds for Claude Code completions — customizable beeps when your session finishes",
5
5
  "keywords": ["claude", "claude-code", "notification", "sound", "beep", "alert"],
6
6
  "license": "MIT",
Binary file
Binary file