Skip to content

Commit

Permalink
Merge pull request hashrocket#262 from hashrocket/add-reason
Browse files Browse the repository at this point in the history
Add a task to create the ReasonML channel
  • Loading branch information
jwworth committed Feb 9, 2018
2 parents 52da063 + 32ae3d8 commit 44c40c4
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions lib/mix/tasks/add_reason.ex
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
defmodule Mix.Tasks.AddReason do
use Mix.Task
alias Mix.{Project}
alias Tilex.{Channel, Repo}

@shortdoc "Add a new channel"
@moduledoc """
This will add a new channel to our databases.
"""

def run(_) do
Application.ensure_all_started(Project.config()[:app])
Repo.insert!(%Channel{name: "reasonml", twitter_hashtag: "reasonml"})
end
end

0 comments on commit 44c40c4

Please sign in to comment.