diff --git a/Formula/twilio.rb b/Formula/twilio.rb index 4162966..38e6f21 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-v3.4.2/twilio-v3.4.2.tar.gz" - version "3.4.2" - sha256 "0f2d3448baee770e091b7c20725d05dd1ecdb48ad435ffc2d7c778b58f8c7c76" + url "https://twilio-cli-prod.s3.amazonaws.com/twilio-v3.5.0/twilio-v3.5.0.tar.gz" + version "3.5.0" + sha256 "b1cd2ce96cc617ef05c107e554d8de5ecaddda10bd7313fc34635b51a771ae9c" depends_on "node" def install diff --git a/Formula/twilio@3.4.2.rb b/Formula/twilio@3.4.2.rb new file mode 100644 index 0000000..ff6b876 --- /dev/null +++ b/Formula/twilio@3.4.2.rb @@ -0,0 +1,21 @@ +require "language/node" + +class TwilioAT342 < 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-v3.4.2/twilio-v3.4.2.tar.gz" + version "3.4.2" + sha256 "0f2d3448baee770e091b7c20725d05dd1ecdb48ad435ffc2d7c778b58f8c7c76" + 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