open-index/open-npm huggingface dataset:
npm package: @sequencemedia/itunes-library
Description: Watch iTunes Library XML and parse to M3U
Author: Jonathan Perry for Sequence Media Limited
Latest version: 0.1.28
Deprecated: No longer maintained

# @sequencemedia/itunes-library

Parses an `iTunes Library.xml` file and transforms it to [`m3u`](https://en.wikipedia.org/wiki/M3U) files, JSON, or JavaScript.

The command line app can watch for changes to an `iTunes Library.xml` file and write `m3u` files to a destination directory.

Or, the component functions can be imported into your own application. 

This packages implements [`@sequencemedia/itunes-library-parser`](https://github.com/sequencemedia/itunes-library-parser).

Requires [Java](https://www.oracle.com/java/technologies/javase-downloads.html) and [Saxon PE](https://www.saxonica.com/welcome/welcome.xml).

## Command line app

```
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"
```

Paths will differ on your device.

## Library

Transforms the entire library.

```javascript
const { toM3U } = require('./lib/library')
const {
  toJSON,
  toJS,
  toES
 } = require('./lib/library/transform')
```

### `toM3U`

Requires the arguments `jar`, `xml`, and `destination`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file
- `destination` - the path for the `m3u` files to be written

Returns a `Promise` resolving when all `m3u` files are written.

### `toJSON`

Requires the arguments `jar`, and `xml`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file

Returns a `Promise` resolving to a `JSON` string.

### `toJS`

Requires the arguments `jar`, and `xml`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file

Returns a `Promise` resolving to a JavaScript object.

### `toES`

Requires the arguments `jar`, and `xml`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file

Returns a `Promise` resolving to a collection of JavaScript `Map` and `Set` instances.

## Playlists

Transforms the playlists.

```javascript
const { toM3U } = require('./lib/library/playlists')
const {
  toJSON,
  toJS,
  toES
 } = require('./lib/library/playlists/transform')
```

See **Library**.

## Tracks

Transforms the tracks.

```javascript
const { toM3U } = require('./lib/library/tracks')
const {
  toJSON,
  toJS,
  toES
 } = require('./lib/library/tracks/transform')
```

See **Library**.
npm package: @sequencemedia/itunes-library-parser
Description: Parse iTunes Library XML files to JSON or M3U
Author: Jonathan Perry for Sequence Media Limited
Latest version: 0.1.22
Deprecated: No longer maintained

# @sequencemedia/itunes-library-parser

JavaScript functions and XSL stylesheets to parse an `iTunes Library.xml` file and transform it to [`m3u`](https://en.wikipedia.org/wiki/M3U) files, JSON, or JavaScript.

Requires [Java](https://www.oracle.com/java/technologies/javase-downloads.html) and [Saxon PE](https://www.saxonica.com/welcome/welcome.xml).

## Library

Transforms the entire library.

```javascript
const { toM3U } = require('./lib/js/library')
const {
  toJSON,
  toJS,
  toES
 } = require('./lib/js/library/transform')
```

### `toM3U`

Requires the arguments `jar`, `xml`, and `destination`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file
- `destination` - the path for the `m3u` files to be written

Returns a `Promise` resolving when all `m3u` files are written.

### `toJSON`

Requires the arguments `jar`, and `xml`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file

Returns a `Promise` resolving to a `JSON` string.

### `toJS`

Requires the arguments `jar`, and `xml`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file

Returns a `Promise` resolving to a JavaScript object.

### `toES`

Requires the arguments `jar`, and `xml`.

- `jar` - the path to the Saxon binary on your device
- `xml` - the path to the `iTunes Library.xml` file

Returns a `Promise` resolving to a collection of JavaScript `Map` and `Set` instances.

## Playlists

Transforms the playlists.

```javascript
const { toM3U } = require('./lib/js/library/playlists')
const {
  toJSON,
  toJS,
  toES
 } = require('./lib/js/library/playlists/transform')
```

See **Library**.

## Tracks

Transforms the tracks.

```javascript
const { toM3U } = require('./lib/js/library/tracks')
const {
  toJSON,
  toJS,
  toES
 } = require('./lib/js/library/tracks/transform')
```

See **Library**.
npm package: @sequencemedia/itunes-library-stream
Description: Streaming parser for the contents of iTunes Library XML files
Author: Jonathan Perry for Sequence Media Limited
Latest version: 0.0.22
Deprecated: No longer maintained

# @sequencemedia/itunes-library-stream

Streaming parser for iTunes Library XML files

## Usage

### `itunes.createStream()`

Creates a stream to parse the `iTunes Library.xml` file and generate:

* Each track
* A collection of all tracks
* Each playlist
* A collection of all playlists
* Each playlist item
* Each collection of playlist items
* The complete library

Every object is defined either as a `Map` or a `Set` (depending on whichever more closely resembles the XML).

### Example ES

```
import { createReadStream } from 'fs'
import { resolve } from 'path'
import userhome from 'userhome'
import itunes from '@sequencmedia/itunes-library-stream'

import itunes, {
  LIBRARY,
  TRACKS,
  TRACK,
  PLAYLISTS,
  PLAYLIST,
  PLAYLIST_ITEMS,
  PLAYLIST_ITEM
} from '@sequencemedia/itunes-library-stream'

const filePath = resolve(userhome(), 'Music/iTunes/iTunes Music Library.xml')

createReadStream(filePath)
  .pipe(itunes.createStream())
  .on('data', ({
  	[LIBRARY]: library,
  	[TRACKS]: tracks,
  	[TRACK]: track,
  	[PLAYLISTS]: playlists,
  	[PLAYLIST]: playlist,
  	[PLAYLIST_ITEMS]: playlistItems,
  	[PLAYLIST_ITEM]: playlistItem
  }) => {
  	if (library) { /* A `Map` instance, contains _all_ tracks and playlists */ }
  	if (tracks) { /* A `Map` instance, contains _all_ tracks  */ }
  	if (track) { /* A `Map` instance. A track  */ }
  	if (playlists) { /* A `Set` instance, contains _all_ playlists */ }
  	if (playlist) { /* A `Map` instance. A playlist  */ }
  	if (playlistItems) { /* A `Set` instance, contains _all_ playlist items (belonging to a playlist) */ }
  	if (playlistItem) { /* A `Map` instance. A playlist item (belonging to a playlist) */ }
  })
  .on('end', () => {
  	console.log('Processing is complete!')
  })
```

## License ##

MIT. See [LICENSE.md](http://github.com/hughsk/itunes-library-stream/blob/master/LICENSE.md) for details.
npm package: @sequencemedia/itunes-library-transformer
Description: Implements `@sequencemedia/itunes-library-stream` to transform an `iTunes Library.xml` file to [`m3u`](https://en.wikipedia.org/wiki/M3U) files
Author: Jonathan Perry for Sequence Media Limited
Latest version: 0.0.18
Deprecated: No longer maintained

# @sequencemedia/itunes-library-transformer

Implements `@sequencemedia/itunes-library-stream` to transform an `iTunes Library.xml` file to [`m3u`](https://en.wikipedia.org/wiki/M3U) files

## License ##

MIT. See [LICENSE.md](http://github.com/hughsk/itunes-library-stream/blob/master/LICENSE.md) for details.
npm package: @sequencemedia/ps
Description: Get a list of process statuses in a convenient structure
Latest version: 0.0.110

# @sequencemedia/ps

Get a list of process statuses in a convenient structure

This project is a fork of *[ps-list](https://github.com/sindresorhus/ps-list)* `v8.1.1` and simplifed _for *macOS* and *Linux*_

```bash
npm i -P @sequencemedia/ps
```

## Usage

```javascript
import ps from '@sequencemedia/ps'

/**
 *  ...
 */

const array = await ps()
```