unreleased-cli 0.1.5 → 0.1.6
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 +1 -1
- package/dist/unreleased.mjs +8 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -97,7 +97,7 @@ Music plays through a hidden mpv that the interactive shell starts the first tim
|
|
|
97
97
|
- `playlist play <name>`, `playlist shuffle <name>`, `liked play` and `shuffle <era> [count]` replace the queue.
|
|
98
98
|
- `queue add` and `queue next` add to it. `queue` lists it, and `remove N` / `jump N` change it.
|
|
99
99
|
- Shuffle, repeat, previous and the end of the queue behave as they do on the site.
|
|
100
|
-
- `status` (or `now`) shows the song, a progress bar, the settings and the queue.
|
|
100
|
+
- `status` (or `now`) shows the song, a progress bar, the settings and the queue, and follows along live on a terminal (`q` leaves). `status -1` prints it once, and it does too when piped or run in a script.
|
|
101
101
|
- `like` and `unlike` with no song act on the one playing.
|
|
102
102
|
|
|
103
103
|
The music stops when you leave the shell, so `unreleased play …` on its own says to open the shell instead. If the shell is killed without a chance to stop mpv (for example the terminal window is closed), mpv quits by itself within about 10 seconds.
|
package/dist/unreleased.mjs
CHANGED
|
@@ -82,7 +82,7 @@ function saveSettings(settings) {
|
|
|
82
82
|
|
|
83
83
|
// src/api.ts
|
|
84
84
|
var DEFAULT_API = "https://juicewrldapi.com/juicewrld";
|
|
85
|
-
var VERSION = "0.1.
|
|
85
|
+
var VERSION = "0.1.6";
|
|
86
86
|
function apiBase() {
|
|
87
87
|
return (process.env.UNRELEASED_API || loadConfig().api || DEFAULT_API).replace(/\/+$/, "");
|
|
88
88
|
}
|
|
@@ -3813,10 +3813,14 @@ var PLAYER_COMMANDS = [
|
|
|
3813
3813
|
name: "status",
|
|
3814
3814
|
aliases: ["now", "np"],
|
|
3815
3815
|
group: "Player",
|
|
3816
|
-
usage: "status",
|
|
3817
|
-
description: "What is playing, plus volume, speed, shuffle, repeat and the queue",
|
|
3818
|
-
run: async (
|
|
3816
|
+
usage: "status [-1]",
|
|
3817
|
+
description: "What is playing, plus volume, speed, shuffle, repeat and the queue. Live on a terminal (q leaves); -1 prints it once",
|
|
3818
|
+
run: async (args, sh) => {
|
|
3819
3819
|
const p = playerOf(sh);
|
|
3820
|
+
if (!sh.scripted && canOpenScreen() && args.trim() !== "-1") {
|
|
3821
|
+
await sh.execLine("watch -n 1 status -1");
|
|
3822
|
+
return;
|
|
3823
|
+
}
|
|
3820
3824
|
const t = p.current;
|
|
3821
3825
|
const [paused, pos, dur] = await Promise.all([p.paused(), p.position(), p.duration()]);
|
|
3822
3826
|
sh.print([
|