@sequencemedia/music-library 1.0.0 → 1.0.1

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.
Files changed (2) hide show
  1. package/README.md +21 -18
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,19 +1,22 @@
1
- # @sequencemedia/itunes-library
1
+ # @sequencemedia/music-library
2
2
 
3
- Parses an `iTunes Library.xml` file and transforms it to [`m3u`](https://en.wikipedia.org/wiki/M3U) files, JSON, or JavaScript.
3
+ Parses an Apple Music `Library.xml` file and transforms it to [`m3u`](https://en.wikipedia.org/wiki/M3U) files, JSON, JavaScript, or EcmaScript.
4
4
 
5
- The command line app can watch for changes to an `iTunes Library.xml` file and write `m3u` files to a destination directory.
5
+ The command line app can watch for changes to an Apple Music `Library.xml` file and write `m3u` files to a destination directory.
6
6
 
7
7
  Or, the component functions can be imported into your own application.
8
8
 
9
- This packages implements [`@sequencemedia/itunes-library-parser`](https://github.com/sequencemedia/itunes-library-parser).
9
+ This packages implements [`@sequencemedia/music-library-parser`](https://github.com/sequencemedia/music-library-parser).
10
10
 
11
11
  Requires [Java](https://www.oracle.com/java/technologies/javase-downloads.html) and [Saxon PE](https://www.saxonica.com/welcome/welcome.xml).
12
12
 
13
13
  ## Command line app
14
14
 
15
15
  ```
16
- npm run start -- --jar "/usr/local/bin/saxon/SaxonPE10-0J/saxon-pe-10.0.jar" --xml "~/Music/iTunes/iTunes Library.xml" --destination "~/Documents/iTunes Library"
16
+ npm run start -- \
17
+ --jar "/usr/local/bin/saxon/SaxonPE10-6J/saxon-pe-10.6.jar" \
18
+ --xml "~/Music/Music/Library.xml" \
19
+ --destination "~/Documents/Music Library"
17
20
  ```
18
21
 
19
22
  Paths will differ on your device.
@@ -23,12 +26,12 @@ Paths will differ on your device.
23
26
  Transforms the entire library.
24
27
 
25
28
  ```javascript
26
- const { toM3U } = require('./lib/library')
27
- const {
29
+ import { toM3U } from './src/library/index.mjs'
30
+ import {
28
31
  toJSON,
29
32
  toJS,
30
33
  toES
31
- } = require('./lib/library/transform')
34
+ } from './src/library/transform/index.mjs'
32
35
  ```
33
36
 
34
37
  ### `toM3U`
@@ -36,7 +39,7 @@ const {
36
39
  Requires the arguments `jar`, `xml`, and `destination`.
37
40
 
38
41
  - `jar` - the path to the Saxon binary on your device
39
- - `xml` - the path to the `iTunes Library.xml` file
42
+ - `xml` - the path to the Apple Music `Library.xml` file
40
43
  - `destination` - the path for the `m3u` files to be written
41
44
 
42
45
  Returns a `Promise` resolving when all `m3u` files are written.
@@ -46,7 +49,7 @@ Returns a `Promise` resolving when all `m3u` files are written.
46
49
  Requires the arguments `jar`, and `xml`.
47
50
 
48
51
  - `jar` - the path to the Saxon binary on your device
49
- - `xml` - the path to the `iTunes Library.xml` file
52
+ - `xml` - the path to the Apple Music `Library.xml` file
50
53
 
51
54
  Returns a `Promise` resolving to a `JSON` string.
52
55
 
@@ -55,7 +58,7 @@ Returns a `Promise` resolving to a `JSON` string.
55
58
  Requires the arguments `jar`, and `xml`.
56
59
 
57
60
  - `jar` - the path to the Saxon binary on your device
58
- - `xml` - the path to the `iTunes Library.xml` file
61
+ - `xml` - the path to the Apple Music `Library.xml` file
59
62
 
60
63
  Returns a `Promise` resolving to a JavaScript object.
61
64
 
@@ -64,7 +67,7 @@ Returns a `Promise` resolving to a JavaScript object.
64
67
  Requires the arguments `jar`, and `xml`.
65
68
 
66
69
  - `jar` - the path to the Saxon binary on your device
67
- - `xml` - the path to the `iTunes Library.xml` file
70
+ - `xml` - the path to the Apple Music `Library.xml` file
68
71
 
69
72
  Returns a `Promise` resolving to a collection of JavaScript `Map` and `Set` instances.
70
73
 
@@ -73,12 +76,12 @@ Returns a `Promise` resolving to a collection of JavaScript `Map` and `Set` inst
73
76
  Transforms the playlists.
74
77
 
75
78
  ```javascript
76
- const { toM3U } = require('./lib/library/playlists')
77
- const {
79
+ import { toM3U } from './src/library/playlists/index.mjs'
80
+ import {
78
81
  toJSON,
79
82
  toJS,
80
83
  toES
81
- } = require('./lib/library/playlists/transform')
84
+ } from './src/library/playlists/transform/index.mjs'
82
85
  ```
83
86
 
84
87
  See **Library**.
@@ -88,12 +91,12 @@ See **Library**.
88
91
  Transforms the tracks.
89
92
 
90
93
  ```javascript
91
- const { toM3U } = require('./lib/library/tracks')
92
- const {
94
+ import { toM3U } from './src/library/tracks/index.mjs'
95
+ import {
93
96
  toJSON,
94
97
  toJS,
95
98
  toES
96
- } = require('./lib/library/tracks/transform')
99
+ } from './src/library/tracks/transform/index.mjs'
97
100
  ```
98
101
 
99
102
  See **Library**.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sequencemedia/music-library",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Watch Apple Music Library XML and parse to JSON, JS, ES, or M3U",
5
5
  "keywords": [
6
6
  "music",