norris2codewars allows you to play codewars from Slack and compete to see how can solve the code first!
Credits:
- https://scotch.io/tutorials/building-a-slack-bot-with-node-js-and-chuck-norris-super-powers
- https://www.npmjs.com/package/codewars-client
- Slack API Key
- Codewars API Key
- Any amount of skill
On Linux and Mac OSX
Run with BOT_API_KEY=your_api_key node bin/bot.js
On Windows
Run with set BOT_API_KEY=your_api_key & node bin/bot.js
- Go to :: https://yourorganization.slack.com/services/new/bot
- After successfully adding, copy the API Token
- Get your Codewars API Token: https://www.codewars.com/users/edit
- When running in slack type
codewars setup --token your_token
to setup - This is saved in .config file
- Within Slack type:
codewars train
- If you like what you see type:
codewars yes
- Otherwise type
codewars train
for differnt kata
- Otherwise type
- Use
codewars print
to show instructions again - Submit a snippet with the title
codewars verify
to verify a submission - Use
codewars submit
to submit a successful solution
Use Code Snippet as message
To verify a solution, title codewars verify
must be used
Codewars requires a specific function for each challenge. Use codewars print
to verify the function name. Use the function under ### Provided Code
Use the above function to define your solution, then press Create Snippet
Command | T |
---|---|
codewars setup |
Content column 2 |
codewars train |
Content cell 2 |
codewars print |
Content column 2 |
codewars verify |
Content column 2 |
codewars submit |
Content column 2 |
codewars help |
Content column 2 |