<commit_before>Ruby bindings for [libspotify][] ([![Build Status](https://secure.travis-ci.org/Burgestrand/spotify.png?branch=master)](http://travis-ci.org/Burgestrand/spotify))
================================

    The libspotify C API package allows third party developers to write
    applications that utilize the Spotify music streaming service.

[Spotify][] is a really nice music streaming service, and being able to interact
with it in an API is awesome. libspotify itself is however written in C, making
it unavailable or cumbersome to use for many developers.

This project aims to allow Ruby developers access to all of the libspotify C API,
without needing to reach down to C. However, to use this library to it’s full extent
you will need to learn how to use the Ruby FFI API.

The Spotify gem has:

- [100% API coverage][], including callback support. You’ll be able to use any function from the libspotify library.
- [Automatic garbage collection][]. Piggybacking on Ruby’s GC to manage pointer lifecycle.
- [Parallell function call protection][]. libspotify is not thread-safe, but Spotify protects you.
- [Type conversion and type safety][]. Special pointers for every Spotify type, protecting you from accidental mix-ups.

[100% API coverage]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify/API
[Automatic garbage collection]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify/ManagedPointer
[Parallell function call protection]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify#method_missing-class_method
[Type conversion and type safety]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify/ManagedPointer

The Spotify gem is aimed at experienced developers
--------------------------------------------------
As the raw libspotify API is exposed, the Spotify gem is best coupled with a supporting
library. This library would take a more focused approach to which kind of applications
you can write using it. The Spotify gem itself, however, has very few opinions.

Known supporting libraries:

- [Hallon](https://github.com/Burgestrand/Hallon), the original. Currently Hallon is simply
  a more convenient Spotify gem, written on top of the Spotify gem. It is diverging from its
  previous path, now towards a more focused and opinionated framework. If you’re unsure of
  what to use, start with the Hallon gem!

Do not let this stop you! Despite my harsh words the Spotify API is well suited for experimentation,
and it can be awfully fun to play with. If you need any assitance feel free to post a message
on the mailing list: [<EMAIL>][] (<https://groups.google.com/d/forum/ruby-hallon>).

Manually installing libspotify
------------------------------
By default, Spotify uses [the libspotify gem](https://rubygems.org/gems/libspotify) which means you do
not need to install libspotify yourself. However, if your platform is not supported by the libspotify
gem you will need to install libspotify yourself.

Please note, that if your platform is not supported by the libspotify gem I’d very much appreciate it
if you could create an issue on [libspotify gem issue tracker](https://github.com/Burgestrand/libspotify/issues)<commit_msg>Update the README on the status of Hallon<commit_after>Ruby bindings for [libspotify][] ([![Build Status](https://secure.travis-ci.org/Burgestrand/spotify.png?branch=master)](http://travis-ci.org/Burgestrand/spotify))
================================

    The libspotify C API package allows third party developers to write
    applications that utilize the Spotify music streaming service.

[Spotify][] is a really nice music streaming service, and being able to interact
with it in an API is awesome. libspotify itself is however written in C, making
it unavailable or cumbersome to use for many developers.

This project aims to allow Ruby developers access to all of the libspotify C API,
without needing to reach down to C. However, to use this library to it’s full extent
you will need to learn how to use the Ruby FFI API.

The Spotify gem has:

- [100% API coverage][], including callback support. You’ll be able to use any function from the libspotify library.
- [Automatic garbage collection][]. Piggybacking on Ruby’s GC to manage pointer lifecycle.
- [Parallell function call protection][]. libspotify is not thread-safe, but Spotify protects you.
- [Type conversion and type safety][]. Special pointers for every Spotify type, protecting you from accidental mix-ups.

[100% API coverage]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify/API
[Automatic garbage collection]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify/ManagedPointer
[Parallell function call protection]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify#method_missing-class_method
[Type conversion and type safety]: http://rdoc.info/github/Burgestrand/spotify/master/Spotify/ManagedPointer

The Spotify gem is aimed at experienced developers
--------------------------------------------------
As the raw libspotify API is exposed, the Spotify gem is best coupled with a supporting
library. This library would take a more focused approach to which kind of applications
you can write using it. The Spotify gem itself, however, has very few opinions.

Known supporting libraries:

- [Hallon](https://github.com/Burgestrand/Hallon). Hallon attempted to be a one-gem-does-all,
  at a higher abstraction level than the Spotify gem. It features a slightly more convenient
  API for certain things, and requires no ruby FFI knowledge, but it is not really an expert
  on any use case.

The Spotify API is well suited for experimentation, and it can be awfully fun to play with.
The examples/ directory contains example code for achieving certain tasks with the Spotify gem.

If you need any assitance feel free to post a message on the mailing list: [<EMAIL>][].

Manually installing libspotify
------------------------------
By default, Spotify uses [the libspotify gem](https://rubygems.org/gems/libspotify) which means you do
not need to install libspotify yourself. However, if your platform is not supported by the libspotify
gem you will need to install libspotify yourself.

Please note, that if your platform is not supported by the libspotify gem I’d very much appreciate it
if you could create an issue on [libspotify gem issue tracker](https://github.com/Burgestrand/libspotify/issues)
{'fraction_non_alphanumeric': 0.10157837162056571, 'fraction_numerical': 0.001875293014533521, 'mean_word_length': 4.194805194805195, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 9, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3572627', 'n_tokens_mistral': 1711, 'n_tokens_neox': 1624, 'n_words': 798}