postlight / hubot-spotify-playlist Goto Github PK
View Code? Open in Web Editor NEWAllows the ability to add/remove/findTracks to a Spotify Playlist.
Allows the ability to add/remove/findTracks to a Spotify Playlist.
On the first run when the bot gets its access/refresh tokens, it displays it.
Maybe can provide a link to preview the song on the search result. Would make things a bit easier
Instead of doing a search and adding a track, it looks like it might be a good idea to just do a straight out search and post the first entry.
Since these commands are typed by non-programmers, English words are common for Hubot plugins.
findTrack
could become spotify find <query>
addTrack
could become spotify queue <query>
getToken
could become spotify get token
removeTrack
could become spotify (unqueue|remove) <query>
Since it's just a key / value store, I can imagine something stepping on your data. One approach I've seen is in hubot-plusplus.
Quite a bit of duplication, should clean it up.
From #1.
Oh interesting, I didn't realize that limitation existed. It sounds like something that should be rolled into the bot. The bot itself has a Redis-based brain that can store data between requests. Perhaps we could authenticate and have it re-authenticate behind the scenes as necessary? Or at least save the last key.
The bot is currently making a post entry for each search result. Lets combine them so its just a single post.
Please change robot.hear
to robot.listen
in these 4 instances: https://github.com/postlight/hubot-spotify-playlist/blob/master/src/spotify-playlist.coffee#L124-L133.
Since this is using robot.hear
, when I run the bot locally (even with a different name), it responds to text matches regardless of the preceding name.
robot.hear
- callback is called anytime a message's text matches
robot.respond
- callback is only called for messages that are immediately preceded by the robot's name or alias
Hear vs. listen: https://github.com/github/hubot/blob/master/docs/scripting.md#hearing-and-responding
I tried to submit a PR for this myself but was denied due to permissions.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.