Skip to content
This repository has been archived by the owner on Nov 28, 2018. It is now read-only.
/ radio-gaga Public archive

Simple web radio player for my elderly mother, no ads, no popups, no settings.

License

Notifications You must be signed in to change notification settings

szkrd/radio-gaga

Repository files navigation

radio-gaga

Simple web radio player for my elderly mother, no ads, no popups, no settings.

My primary target is a rooted Nexus 7 (android 5.1.1, XenonHD), if you need support for other devices, feel free to PR.

The APK has not been uploaded to the play store, I use "unknown sources" and manual installs, the device has no gapps installed as a matter of fact.

installation

  1. npm i
  2. sudo npm install -g cordova
  3. cordova requirements
  4. follow cordova instructions! (install java jdk, android sdk, gradle, etc.)

development

  • npm run dev starts a webpack server
  • npm run preview:browser builds a js pack, starts koa static, opens browser
  • check .env.sample for env vars

For android enable "usb debugging" and "unknown sources". Run npm run preview:android to upload the app directly to the device.

If you want to upload the apk manually, then disable the "usb debugging" mode.

release

  1. First build the apk: npm run build:android, this will create an unsigned apk in dist.
  2. Symlink or copy your release-key.keystore into the config folder. Create a key with keytool -genkey -v -keystore ./config/release-key.keystore -alias alias_name -keyalg RSA -validity 10000 if you don't have one so far.
  3. Run npm run release:android, if you have the keystore file in place, jdk properly installed - this should create a signed binary in the dist folder.
  4. So far the release drafting has to be done manually on github. Do not forget to upload the signed apk as a binary release.

Build and release together (assuming everything is set up correctly): npm run build:android && npm run release:android

stations

Station list is stored in a json config file (station.json), right now the application itself does not fetch/parse remote sites (the list is compiled into the app itself; downloading a station list json from arbitrary url is possible).

Object format:

  • name: name of the radio channel
  • url: homepage
  • locator: either a suffix to search for in the homepage or an url and a suffix in "url->suffix" format. Use with pls or m3u files, think of it as an extra step.
  • src: the stream url, audio source
  • shoutcastify: shoutcast streams must end with a semicolon, but sometimes it is missing from the source (probably appended by an interim flash player)
  • (timestamp): Date.now generated by test-stations, not required
  • (broken): generated by test-stations, indicates a severe fetch error (404, 500 etc.)

Use npm run test-stations to test and modify the json. If the script fails, update the file manually or implement new parser logic for offending page. Always review the changeset generated by the script.

attribution

The following icons (from www.flaticon.com) are used (CC3.0) in the app:

  • cog by Dave Gandy
  • loading by Google
  • radio by Darius Dan

About

Simple web radio player for my elderly mother, no ads, no popups, no settings.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published