diff --git a/Formula/twilio.rb b/Formula/twilio.rb index a49d237..5290ab4 100644 --- a/Formula/twilio.rb +++ b/Formula/twilio.rb @@ -3,9 +3,9 @@ class Twilio < Formula desc "unleash the power of Twilio from your command prompt" homepage "https://github.com/twilio/twilio-cli" - url "https://twilio-cli-prod.s3.amazonaws.com/twilio-v5.3.3/twilio-v5.3.3.tar.gz" - version "5.3.3" - sha256 "896dfdb081f7acadb0e4f02d24a122576956db75eb62d4c837cb46551e5a6fb1" + url "https://twilio-cli-prod.s3.amazonaws.com/twilio-v1.0.0-rc.5/twilio-v1.0.0-rc.5.tar.gz" + version "1.0.0-rc.5" + sha256 "bc921fc74ac5bdca1529716f795a73fcb019970922df8ec17ec669033630fa00" depends_on "node" def install diff --git a/Formula/twilio@5.3.3.rb b/Formula/twilio@5.3.3.rb new file mode 100644 index 0000000..826238b --- /dev/null +++ b/Formula/twilio@5.3.3.rb @@ -0,0 +1,21 @@ +require "language/node" + +class TwilioAT533 < Formula + desc "unleash the power of Twilio from your command prompt" + homepage "https://github.com/twilio/twilio-cli" + url "https://twilio-cli-prod.s3.amazonaws.com/twilio-v5.3.3/twilio-v5.3.3.tar.gz" + version "5.3.3" + sha256 "896dfdb081f7acadb0e4f02d24a122576956db75eb62d4c837cb46551e5a6fb1" + depends_on "node" + + def install + inreplace "bin/twilio", /^CLIENT_HOME=/, "export TWILIO_OCLIF_CLIENT_HOME=#{lib/"client"}\nCLIENT_HOME=" + libexec.install Dir["*"] + bin.install_symlink libexec/"bin/twilio" + end + + def post_install + pid = spawn("node #{libexec}/welcome.js") + Process.wait pid + end +end