You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 20, 2019. It is now read-only.
Want to make a contribution to Whenbot? Let's get you started! The main goal of the exercise is to show that it's not all that hard to contribute to an open source project.
We've taken away the hard part of figuring out exactly what to contribute, by providing you with a list of one-liners that need to be added to Whenbot. We've also provided you a step-by-step guide to walk you through the process.
All you need to do is choose a One-Liner from the list below (be sure to reserve your choice), and follow the Contribution Guide here.
Never contributed to Open Source before?
If it's your first time making an Open Source contribution, don't worry, it's not that hard. Be excited, follow the guide below, and very soon you should have made your first Open Source contribution!
How to participate
Follow these steps:
Take a look at the list below and choose a One-Liner to work on.
Make sure that the One-Liner you picked hasn't already been chosen by checking the comments below this post. If your One-Liner has already been reserved, choose another one.
Then, reserve your One-Liner by posting a comment in this thread (below). Just write: "Working on one-liner number one-liner number in file path here, brief description of change". For example:
Working on one-liner number 8 in app/models/task.rb, to make the :name, :active, :trigger_attributes, and :action_attributes attributes accessible.
After posting your comment, you're ready to start working on your update. :)
Once you have your one-liner chosen and reserved, follow the Whenbot One-Liner Contribution Guide to learn how to create your own fork of the app, clone the repository, make your changes, push your changes back to your fork, and issue a Pull Request.
The One-Liners
Choose a One-Liner number below, and follow the instructions above. Soon, you'll have contributed to a cool, new Open-Source project. :)
If you need help, you can find the solution for your one-liner in this branch. Just browse to the file you're working on.
lib/whenbot.rb
Line 15: add a call to #mattr_accessor to create a Module Attribute for :channels
Line 50: Fill in the block to take a Channel class (e.g. Whenbot::Channels::Developer), convert it to a string, and extract the Channel's name out of the string. In the previous example, you'd want to get the word" Developer"
lib/whenbot/trigger.rb
Line 14: In the current_time method, return the current time in the set time zone.
app/controllers/whenbot_controller.rb
Line 6: Call the Task.handle_callback method (found in app/models/task.rb) with the following parameters in the given order, and set the response variable to the return value of that call:
This project has been stalled for a while now actually. It's my fault, I've just been so busy and haven't had the time to get the ball rolling again. I've been trying to set aside some time for this, but I have no idea when I can work on it.
But I'd love to get Whenbot up and running. Any chance you'd be up for helping out with this or making some contributions?
For instance, is there anything you'd like to see added to this document (see links at the end too) in order to feel comfortable contributing to Whenbot? This will give me an idea of what needs to be written to get things moving.
The goal is for it to be a group project for Ottawa Ruby. So once a plan is in place, I think people will start contributing.
Sorry again that it's not ready to go. I hope we can get a usable version out there.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
One-Liners exercise
Want to make a contribution to Whenbot? Let's get you started! The main goal of the exercise is to show that it's not all that hard to contribute to an open source project.
We've taken away the hard part of figuring out exactly what to contribute, by providing you with a list of one-liners that need to be added to Whenbot. We've also provided you a step-by-step guide to walk you through the process.
All you need to do is choose a One-Liner from the list below (be sure to reserve your choice), and follow the Contribution Guide here.
Never contributed to Open Source before?
If it's your first time making an Open Source contribution, don't worry, it's not that hard. Be excited, follow the guide below, and very soon you should have made your first Open Source contribution!
How to participate
Follow these steps:
Take a look at the list below and choose a One-Liner to work on.
Make sure that the One-Liner you picked hasn't already been chosen by checking the comments below this post. If your One-Liner has already been reserved, choose another one.
Then, reserve your One-Liner by posting a comment in this thread (below). Just write: "Working on one-liner number
one-liner number
infile path here
,brief description of change
". For example:Working on one-liner number 8 in
app/models/task.rb
, to make the:name
,:active
,:trigger_attributes
, and:action_attributes
attributes accessible.After posting your comment, you're ready to start working on your update. :)
Once you have your one-liner chosen and reserved, follow the Whenbot One-Liner Contribution Guide to learn how to create your own fork of the app, clone the repository, make your changes, push your changes back to your fork, and issue a Pull Request.
The One-Liners
Choose a One-Liner number below, and follow the instructions above. Soon, you'll have contributed to a cool, new Open-Source project. :)
If you need help, you can find the solution for your one-liner in this branch. Just browse to the file you're working on.
lib/whenbot.rb
lib/whenbot/trigger.rb
current_time
method, return the current time in the set time zone.app/controllers/whenbot_controller.rb
Task.handle_callback
method (found inapp/models/task.rb
) with the following parameters in the given order, and set the response variable to the return value of that call:params[:channel], params[:trigger], params, request.headers, request.body.read
#validate_response
method to "#parse_response``.app/models/task.rb
has_many
association with theAction
model:name, :active, :trigger_attributes, :action_attributes
Trigger#save_updated_triggers
method withreturned_triggers
, andtrigger_ids
as parameters.response
app/models/trigger.rb
scope
) calledactive
that returns records where theactive
field is set totrue
parameters
field to be serializable as aHash
match_data
field to be serializable as aHash
extra_data
field to be serializable as aHash
Task
modelchannel, trigger, parameters, active
channel
,trigger
, and ``parametersThe text was updated successfully, but these errors were encountered: