rocksky 0.5.0 → 0.6.0
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.
- checksums.yaml +4 -4
- data/README.md +6 -3
- data/lib/rocksky/manifest.json +7 -7
- data/lib/rocksky/version.rb +1 -1
- data/lib/rocksky.rb +8 -3
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fa6c83fa81b7bb244115d6b179b278f592dbbade9efdbcb5ec1d4b0f7e2d4b9c
|
|
4
|
+
data.tar.gz: 410f0dda9e50cdc5b60f39d84d3184cc740db1937672fa3f63417b77665e46a6
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0b0f47853567386514a64edd0beca2ea4c1ab0561f5834371c1756566e026681d0456876c7adacc3d6c1d957be83e3735e0ed5b1e9c9c940c1495851362075d8
|
|
7
|
+
data.tar.gz: 190f6cbdba923e62b13332f6a04f897c07dec5a5b8098ee7cfc4947b15088dd721deae25778ed9a3ea26b1a4bf3f1926c9891b6c81e5ddce367cc7761324f7a6
|
data/README.md
CHANGED
|
@@ -14,7 +14,7 @@ gem install rocksky
|
|
|
14
14
|
Or in a Gemfile:
|
|
15
15
|
|
|
16
16
|
```ruby
|
|
17
|
-
gem "rocksky", "~> 0.
|
|
17
|
+
gem "rocksky", "~> 0.6"
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
The gem is pure-Ruby; the native library is fetched from the GitHub release on
|
|
@@ -92,11 +92,14 @@ below). Then `scrobble(track)` (fans out to artist/album/song/scrobble),
|
|
|
92
92
|
`refresh_session`, and `close` (release the native handle).
|
|
93
93
|
|
|
94
94
|
**Two scrobble paths** — `scrobble(track)` takes full metadata, while
|
|
95
|
-
`scrobble_match(
|
|
95
|
+
`scrobble_match(params)` takes a single Hash with camelCase string keys —
|
|
96
|
+
required `"title"`/`"artist"`, optional `"album"` (override), `"mbId"`/`"isrc"`
|
|
97
|
+
(match anchors), `"timestamp"` (scrobbled-at Unix seconds) — matching a bare
|
|
96
98
|
title + artist first, then writes.
|
|
97
99
|
|
|
98
100
|
```ruby
|
|
99
|
-
agent.scrobble_match("Chaser", "Calibro 35",
|
|
101
|
+
agent.scrobble_match("title" => "Chaser", "artist" => "Calibro 35",
|
|
102
|
+
"album" => "Jazzploitation")
|
|
100
103
|
```
|
|
101
104
|
|
|
102
105
|
**Dedup + realtime** — with `dedup_path:` set at login, `agent.sync_repo`
|
data/lib/rocksky/manifest.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"repo": "tsirysndr/rocksky",
|
|
3
|
-
"tag": "bindings-v0.
|
|
3
|
+
"tag": "bindings-v0.3.0",
|
|
4
4
|
"checksums": {
|
|
5
|
-
"aarch64-apple-darwin": "
|
|
6
|
-
"aarch64-linux-gnu": "
|
|
7
|
-
"x86_64-apple-darwin": "
|
|
8
|
-
"x86_64-linux-gnu": "
|
|
9
|
-
"x86_64-unknown-freebsd": "
|
|
10
|
-
"x86_64-unknown-netbsd": "
|
|
5
|
+
"aarch64-apple-darwin": "645f343ba39bbcaa62ed38a56b8b9d88010d20e8e1f7488b691eab751f05d52d",
|
|
6
|
+
"aarch64-linux-gnu": "d8939244fa7fac3b56e83012fc30c87dc50b8531e21f860ab324159d38d5e78d",
|
|
7
|
+
"x86_64-apple-darwin": "9702077e8793c2a3c07c345e684c0918da04a44c71668c862fb516a75af61763",
|
|
8
|
+
"x86_64-linux-gnu": "964afa99734213465343daf3c5e5681be7c1a5a5d656a7030b5f2cc2b3bcea23",
|
|
9
|
+
"x86_64-unknown-freebsd": "e827e572d9d18eb9996607a9107bed4e28aaea0878f744b152bd3e6afec05bf4",
|
|
10
|
+
"x86_64-unknown-netbsd": "78744d465bbcbbe2f7fc61e36e554153d9a8334ac471e52f65c997c1beaeb455"
|
|
11
11
|
}
|
|
12
12
|
}
|
data/lib/rocksky/version.rb
CHANGED
data/lib/rocksky.rb
CHANGED
|
@@ -36,7 +36,7 @@ module Rocksky
|
|
|
36
36
|
"void* rocksky_agent_login(const char*, const char*, const char*, const char*, const char*)",
|
|
37
37
|
"void rocksky_agent_free(void*)",
|
|
38
38
|
"char* rocksky_agent_scrobble(void*, const char*)",
|
|
39
|
-
"char* rocksky_agent_scrobble_match(void*, const char
|
|
39
|
+
"char* rocksky_agent_scrobble_match(void*, const char*)",
|
|
40
40
|
"char* rocksky_agent_sync_repo(void*)",
|
|
41
41
|
"char* rocksky_agent_hydrate_from_jetstream(void*)",
|
|
42
42
|
"char* rocksky_agent_like(void*, const char*, const char*)",
|
|
@@ -166,8 +166,13 @@ module Rocksky
|
|
|
166
166
|
|
|
167
167
|
# Scrobble from just a title + artist (album optional, plus optional mb_id /
|
|
168
168
|
# isrc anchors): resolve full metadata via matchSong, then fan out.
|
|
169
|
-
|
|
170
|
-
|
|
169
|
+
# Scrobble from just a title + artist. +input+ is a Hash with camelCase keys:
|
|
170
|
+
# required "title"/"artist"; optional "album", "mbId", "isrc" (match anchors),
|
|
171
|
+
# and "timestamp" (scrobbled-at Unix seconds, default now).
|
|
172
|
+
#
|
|
173
|
+
# agent.scrobble_match("title" => "Chaser", "artist" => "Calibro 35")
|
|
174
|
+
def scrobble_match(input)
|
|
175
|
+
Rocksky.unwrap(C.rocksky_agent_scrobble_match(@ptr, JSON.generate(input)))
|
|
171
176
|
end
|
|
172
177
|
|
|
173
178
|
# Download the caller's repo and (re)build the local dedup index (needs a
|