SlideShare ist ein Scribd-Unternehmen logo
1 von 27
Downloaden Sie, um offline zu lesen
HUBOT
A LOOK INSIDE OUR ROBOT FRIEND
1.   Setting Up Hubot
2.   Coffeescript Primer
3.   Hubot Overview
4.   APIs
(disclaimer: this assumes OSX. commands should
       translate easily to windows and linux.)
PREREQUISITES
              Install Node
           be isalnd
            rw ntl oe
           Install and run Redis
add / s / o a / h r / p / i to your path
     urlclsaenmbn
         Install Hubot
    nmisal- cfe-cit
     p ntl g ofesrp
         nmisal- hbt
          p ntl g uo
      An Heroku account is suggested.
FIND A NICE HOME
          c to directory of choice
           d
run h b t - a r o to generate a boilerplate
     uo c ibt
                c aro
                 d ibt
           cmd+ bnhbt
            ho x i/uo
HELLO WORLD
      run b n h b t
           i/uo
type h b t p n and hit enter
      uo ig
A BRIEF DIVERSION INTO
     COFFEESCRIPT
itoesg =(sr -
nrMsae   ue) >
  i ue?nm?adue?hby
   f sr.ae n sr.ob?
    "el,Ia #rsos.ae,"+
     hlo  m {epnenm}
         " #rsos.ob}s.
          a {epnehbyit"
  es
   le
    msae="laetl m mr aotyusl.
     esg  Pes el e oe bu oref"

  msae
   esg

m =
 e
  nm:"ak
   ae Jc"
  hby "uo crto"
   ob: Hbt uain

cnoelgitoesg(e
osl.o nrMsaem)

#el,Ia Jc,aHbtcrtoit
hlo   m ak  uo uains
HUBOT STRUCTURE
P o f l (Heroku startup script)
 rcie
RAM.d
 EDEm
b n (contains hubot executable)
 i/
e t r a - c i t . s n(list of packages from npm)
 xenlsrpsjo
h b t s r p s j o (list of packages from hubot-
 uo-cit.sn
scripts)
p c a e j o (node package manager
 akg.sn
metainformation)
s r p s (custom hubot script directory)
 cit/
A HUBOT SCRIPT
    EXAMPLE
  CREATE AND EDIT
SRPSGOBECFE
CIT/ODY.OFE
gobe =[
 odys
  "y,{ae.,
   Be nm}"
  "ae,{ae.,
   Ltr nm}"
  "aecr,{ae.
   Tk ae nm}"
]

gobe=(ae -
ody   nm) >
 idx=pren(ahrno( *gobe.egh
  ne  asItMt.adm)  odyslnt)
 msae=gobe[ne]
  esg  odysidx
 msaerpae/nm},nm)
  esg.elc({ae/ ae;

mdl.xot =(oo)-
oueeprs     rbt >
 rbtha /beltr,(*/,(s)-
  oo.er (y|ae)?s.)i mg >
   i rbtnm.ooeCs( = mgmth2.ooeCs(
    f oo.aetLwrae) = s.ac[]tLwrae)
     beesg =gobemgmsaeue.ae
      yMsae  ody(s.esg.srnm)
     mgsn(yMsae
      s.edbeesg)
run b n h b tagain
     i/uo
say g o b e H b t
     ody uo
say l t r H b t
     ae, uo
HUBOT-SCRIPTS
       GITHUB.COM/GITHUB/HUBOT-SCRIPTS
hubot will automatically download and keep up-to-date
               any hubot-scripts you add
copy the dependencies from the hubot-script into your
                  pcaejo
                   akg.sn
                from clark.coffee :
 #Dsrpin
   ecito:
 # Nn
    oe
 #
 #Dpnece:
   eednis
 # "lr" ".."
    cak: 005
 #
 #Cniuain
   ofgrto:
 # Nn
    oe
 #
 #Cmad:
   omns
 # hbtcak<aa -bidsakie oto dt
    uo lr dt> ul prlns u f aa
 #
 #Ato:
   uhr
 # aakiid
    jcsfe
edit h b t s r p s j o
       uo-cit.sn
   add " l r . o f e
        cakcfe"
      run b n h b t
           i/uo
say h b t c a k 1 2 3 4 5
     uo lr
HUBOT PERSISTANCE
       simple storage through h b t b a n
                               uo.ri
     overloaded by redis-brain, mongo-brain, etc.
(you can find these in hubot-scripts or write your own)
You can save any arbitrary data in the brain.
#yumywn t wi utltebanhsbe iiilzd
  o a at o at ni h ri a en ntaie
#adteei adtbs cneto
  n hr s  aaae oncin
rbtbano 'odd,-
oo.ri.n lae' >
 rbtbanlsAcse =nwDt(
  oo.ri.atcesd    e ae)
 rbtbansaul =1
  oo.ri.egls   2
 rbtbanfoes={pnis tu,dfois fle}
  oo.ri.lwr     ase: re afdl: as


 #hbtbanrn o eet
   uo ri us n vns
 rbtbanei 'ae
  oo.ri.mt sv'
HUBOT HTTP LISTENER
   CREATE AND EDIT
  SRPSSYCFE
   CIT/A.OFE
qeytig=rqie'ursrn'
ursrn   eur(qeytig)

mdl.xot =(oo)-
oueeprs    rbt >
 rbtrue.e "hbtsy,(e,rs -
  oo.otrgt /uo/a" rq e) >
   qey=qeytigprerq_asdr.ur)
    ur  ursrn.as(e.preUlqey
   msae=qeymsae
    esg  ur.esg

  ue ={
   sr  }
  ue.om=qeyro i qeyro
   srro  ur.om f ur.om

  rbtsn(sr msae
   oo.edue, esg)
  rsed"ad#msae"
   e.n si {esg}
edit p c a e j o to include
              akg.sn
" u r s r n " " = 0 1 0 in the dependencies
 qeytig: > .."
              run n m i s a l
                   p ntl
               run b n h b t
                    i/uo
  visit l c l o t 8 8 / a ? e s g = e l
         oahs:00symsaehlo
DEPLOYMENT
99 times out of 100, you'll probably just deploy to Heroku
     h b t - creates a Heroku P o f l for you
      uo c                          rcie
                  run H r k c e t
                       eou rae
        deploy with g t p s h r k m s e
                     i uh eou atr
         start with h r k p : c l w b 1
                     eou ssae e=
  (you'll only have to run p : c l this the first time)
                            ssae
CHAT ADAPTERS
Hubot ships with a Campfire adapter. You can get more
                  from hubot-scripts.
         Assuming Heroku deployment, run
                Hrk cni:d
                  eou ofgad
         HBTCMFR_OE=ert
          UO_APIETKNsce
         HBTCMFR_OM=2,5
          UO_APIEROS1346
       HBTCMFR_CON=hbt
         UO_APIEACUT"uo"
Hubot: a look inside our robot friend

Weitere ähnliche Inhalte

Was ist angesagt?

DevChatt 2010 - *nix Cmd Line Kung Foo
DevChatt 2010 - *nix Cmd Line Kung FooDevChatt 2010 - *nix Cmd Line Kung Foo
DevChatt 2010 - *nix Cmd Line Kung Foo
brian_dailey
 
Unix Shell Scripting Basics
Unix Shell Scripting BasicsUnix Shell Scripting Basics
Unix Shell Scripting Basics
Dr.Ravi
 
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basics
Abhay Sapru
 
Gitosis on Mac OS X Server
Gitosis on Mac OS X ServerGitosis on Mac OS X Server
Gitosis on Mac OS X Server
Yasuhiro Asaka
 

Was ist angesagt? (20)

DevChatt 2010 - *nix Cmd Line Kung Foo
DevChatt 2010 - *nix Cmd Line Kung FooDevChatt 2010 - *nix Cmd Line Kung Foo
DevChatt 2010 - *nix Cmd Line Kung Foo
 
Unix Shell Scripting Basics
Unix Shell Scripting BasicsUnix Shell Scripting Basics
Unix Shell Scripting Basics
 
Py conkr 20150829_docker-python
Py conkr 20150829_docker-pythonPy conkr 20150829_docker-python
Py conkr 20150829_docker-python
 
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basics
 
Writing webapps with Perl Dancer
Writing webapps with Perl DancerWriting webapps with Perl Dancer
Writing webapps with Perl Dancer
 
Go初心者がGoでコマンドラインツールの作成に挑戦した話
Go初心者がGoでコマンドラインツールの作成に挑戦した話Go初心者がGoでコマンドラインツールの作成に挑戦した話
Go初心者がGoでコマンドラインツールの作成に挑戦した話
 
Introduction to ansible
Introduction to ansibleIntroduction to ansible
Introduction to ansible
 
Стажировка 2016-07-27 02 Денис Нелюбин. PostgreSQL и jsonb
Стажировка 2016-07-27 02 Денис Нелюбин. PostgreSQL и jsonbСтажировка 2016-07-27 02 Денис Нелюбин. PostgreSQL и jsonb
Стажировка 2016-07-27 02 Денис Нелюбин. PostgreSQL и jsonb
 
Docker, c'est bonheur !
Docker, c'est bonheur !Docker, c'est bonheur !
Docker, c'est bonheur !
 
Gitosis on Mac OS X Server
Gitosis on Mac OS X ServerGitosis on Mac OS X Server
Gitosis on Mac OS X Server
 
An introduction to Rex - FLOSS UK DevOps York 2015
An introduction to Rex - FLOSS UK DevOps York 2015An introduction to Rex - FLOSS UK DevOps York 2015
An introduction to Rex - FLOSS UK DevOps York 2015
 
Txjs
TxjsTxjs
Txjs
 
Quality Use Of Plugin
Quality Use Of PluginQuality Use Of Plugin
Quality Use Of Plugin
 
PerlDancer for Perlers (FOSDEM 2011)
PerlDancer for Perlers (FOSDEM 2011)PerlDancer for Perlers (FOSDEM 2011)
PerlDancer for Perlers (FOSDEM 2011)
 
Perl Dancer, FPW 2010
Perl Dancer, FPW 2010Perl Dancer, FPW 2010
Perl Dancer, FPW 2010
 
Perl Dancer for Python programmers
Perl Dancer for Python programmersPerl Dancer for Python programmers
Perl Dancer for Python programmers
 
Puppet @ Seat
Puppet @ SeatPuppet @ Seat
Puppet @ Seat
 
(WHAT) To Do or Not To Do: Staying Up To Date with PHP Versions
(WHAT) To Do or Not To Do: Staying Up To Date with PHP Versions(WHAT) To Do or Not To Do: Staying Up To Date with PHP Versions
(WHAT) To Do or Not To Do: Staying Up To Date with PHP Versions
 
Augeas
AugeasAugeas
Augeas
 
Shell scripting
Shell scriptingShell scripting
Shell scripting
 

Andere mochten auch

Andere mochten auch (11)

Introduction to hubot
Introduction to hubotIntroduction to hubot
Introduction to hubot
 
ChatOps with Hubot
ChatOps with HubotChatOps with Hubot
ChatOps with Hubot
 
Let's talk ChatOps - Hubot with less CoffeeScript
Let's talk ChatOps - Hubot with less CoffeeScriptLet's talk ChatOps - Hubot with less CoffeeScript
Let's talk ChatOps - Hubot with less CoffeeScript
 
ChatOps meetup: les humains parlent aux robots
ChatOps meetup: les humains parlent aux robotsChatOps meetup: les humains parlent aux robots
ChatOps meetup: les humains parlent aux robots
 
Embrace chatops, stop installing deployment software - Laracon EU 2016
Embrace chatops, stop installing deployment software - Laracon EU 2016Embrace chatops, stop installing deployment software - Laracon EU 2016
Embrace chatops, stop installing deployment software - Laracon EU 2016
 
ChatOps
ChatOpsChatOps
ChatOps
 
Chat ops .. a beginner's guide
Chat ops .. a beginner's guideChat ops .. a beginner's guide
Chat ops .. a beginner's guide
 
AI Machine vs Human
AI Machine vs HumanAI Machine vs Human
AI Machine vs Human
 
Create Your Own Chatbot with Hubot and CoffeeScript
Create Your Own Chatbot with Hubot and CoffeeScriptCreate Your Own Chatbot with Hubot and CoffeeScript
Create Your Own Chatbot with Hubot and CoffeeScript
 
Chatbot workshop - How to build one.#digitized16
Chatbot workshop - How to build one.#digitized16Chatbot workshop - How to build one.#digitized16
Chatbot workshop - How to build one.#digitized16
 
An Introduction To Chat Bots
An Introduction To Chat BotsAn Introduction To Chat Bots
An Introduction To Chat Bots
 

Ähnlich wie Hubot: a look inside our robot friend

Nginx Scripting - Extending Nginx Functionalities with Lua
Nginx Scripting - Extending Nginx Functionalities with LuaNginx Scripting - Extending Nginx Functionalities with Lua
Nginx Scripting - Extending Nginx Functionalities with Lua
Tony Fabeen
 
Devinsampa nginx-scripting
Devinsampa nginx-scriptingDevinsampa nginx-scripting
Devinsampa nginx-scripting
Tony Fabeen
 
The State of PHPUnit
The State of PHPUnitThe State of PHPUnit
The State of PHPUnit
Edorian
 
Introduction to Ansible
Introduction to AnsibleIntroduction to Ansible
Introduction to Ansible
Mattias Gees
 

Ähnlich wie Hubot: a look inside our robot friend (20)

Nginx Scripting - Extending Nginx Functionalities with Lua
Nginx Scripting - Extending Nginx Functionalities with LuaNginx Scripting - Extending Nginx Functionalities with Lua
Nginx Scripting - Extending Nginx Functionalities with Lua
 
Devinsampa nginx-scripting
Devinsampa nginx-scriptingDevinsampa nginx-scripting
Devinsampa nginx-scripting
 
Embedding perl
Embedding perlEmbedding perl
Embedding perl
 
Noah Zoschke at Waza 2013: Heroku Secrets
Noah Zoschke at Waza 2013: Heroku SecretsNoah Zoschke at Waza 2013: Heroku Secrets
Noah Zoschke at Waza 2013: Heroku Secrets
 
Theme Development and Customization
Theme Development and CustomizationTheme Development and Customization
Theme Development and Customization
 
An Introduction to PHP Dependency Management With Composer
An Introduction to PHP Dependency Management With ComposerAn Introduction to PHP Dependency Management With Composer
An Introduction to PHP Dependency Management With Composer
 
Automated tests - facts and myths
Automated tests - facts and mythsAutomated tests - facts and myths
Automated tests - facts and myths
 
WordPress in 30 minutes
WordPress in 30 minutesWordPress in 30 minutes
WordPress in 30 minutes
 
Embed--Basic PERL XS
Embed--Basic PERL XSEmbed--Basic PERL XS
Embed--Basic PERL XS
 
The State of PHPUnit
The State of PHPUnitThe State of PHPUnit
The State of PHPUnit
 
A Backbone.js Tutorial for the Impatient - Part 1
A Backbone.js Tutorial for the Impatient - Part 1A Backbone.js Tutorial for the Impatient - Part 1
A Backbone.js Tutorial for the Impatient - Part 1
 
Apache Hadoop Shell Rewrite
Apache Hadoop Shell RewriteApache Hadoop Shell Rewrite
Apache Hadoop Shell Rewrite
 
Shell scripting
Shell scriptingShell scripting
Shell scripting
 
Building a DSL with GraalVM (VoxxedDays Luxembourg)
Building a DSL with GraalVM (VoxxedDays Luxembourg)Building a DSL with GraalVM (VoxxedDays Luxembourg)
Building a DSL with GraalVM (VoxxedDays Luxembourg)
 
The Power of CSS
The Power of CSSThe Power of CSS
The Power of CSS
 
The State of PHPUnit
The State of PHPUnitThe State of PHPUnit
The State of PHPUnit
 
Beginner workshop to angularjs presentation at Google
Beginner workshop to angularjs presentation at GoogleBeginner workshop to angularjs presentation at Google
Beginner workshop to angularjs presentation at Google
 
Introduction to Ansible
Introduction to AnsibleIntroduction to Ansible
Introduction to Ansible
 
Naughty And Nice Bash Features
Naughty And Nice Bash FeaturesNaughty And Nice Bash Features
Naughty And Nice Bash Features
 
An Introduction to CSS Preprocessors
An Introduction to CSS PreprocessorsAn Introduction to CSS Preprocessors
An Introduction to CSS Preprocessors
 

Kürzlich hochgeladen

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Kürzlich hochgeladen (20)

Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 

Hubot: a look inside our robot friend

  • 1.
  • 2. HUBOT A LOOK INSIDE OUR ROBOT FRIEND
  • 3. 1. Setting Up Hubot 2. Coffeescript Primer 3. Hubot Overview 4. APIs
  • 4.
  • 5. (disclaimer: this assumes OSX. commands should translate easily to windows and linux.)
  • 6. PREREQUISITES Install Node be isalnd rw ntl oe Install and run Redis add / s / o a / h r / p / i to your path urlclsaenmbn Install Hubot nmisal- cfe-cit p ntl g ofesrp nmisal- hbt p ntl g uo An Heroku account is suggested.
  • 7. FIND A NICE HOME c to directory of choice d run h b t - a r o to generate a boilerplate uo c ibt c aro d ibt cmd+ bnhbt ho x i/uo
  • 8. HELLO WORLD run b n h b t i/uo type h b t p n and hit enter uo ig
  • 9. A BRIEF DIVERSION INTO COFFEESCRIPT
  • 10. itoesg =(sr - nrMsae ue) > i ue?nm?adue?hby f sr.ae n sr.ob? "el,Ia #rsos.ae,"+ hlo m {epnenm} " #rsos.ob}s. a {epnehbyit" es le msae="laetl m mr aotyusl. esg Pes el e oe bu oref" msae esg m = e nm:"ak ae Jc" hby "uo crto" ob: Hbt uain cnoelgitoesg(e osl.o nrMsaem) #el,Ia Jc,aHbtcrtoit hlo m ak uo uains
  • 11. HUBOT STRUCTURE P o f l (Heroku startup script) rcie RAM.d EDEm b n (contains hubot executable) i/ e t r a - c i t . s n(list of packages from npm) xenlsrpsjo h b t s r p s j o (list of packages from hubot- uo-cit.sn scripts) p c a e j o (node package manager akg.sn metainformation) s r p s (custom hubot script directory) cit/
  • 12. A HUBOT SCRIPT EXAMPLE CREATE AND EDIT SRPSGOBECFE CIT/ODY.OFE
  • 13. gobe =[ odys "y,{ae., Be nm}" "ae,{ae., Ltr nm}" "aecr,{ae. Tk ae nm}" ] gobe=(ae - ody nm) > idx=pren(ahrno( *gobe.egh ne asItMt.adm) odyslnt) msae=gobe[ne] esg odysidx msaerpae/nm},nm) esg.elc({ae/ ae; mdl.xot =(oo)- oueeprs rbt > rbtha /beltr,(*/,(s)- oo.er (y|ae)?s.)i mg > i rbtnm.ooeCs( = mgmth2.ooeCs( f oo.aetLwrae) = s.ac[]tLwrae) beesg =gobemgmsaeue.ae yMsae ody(s.esg.srnm) mgsn(yMsae s.edbeesg)
  • 14.
  • 15. run b n h b tagain i/uo say g o b e H b t ody uo say l t r H b t ae, uo
  • 16. HUBOT-SCRIPTS GITHUB.COM/GITHUB/HUBOT-SCRIPTS hubot will automatically download and keep up-to-date any hubot-scripts you add
  • 17. copy the dependencies from the hubot-script into your pcaejo akg.sn from clark.coffee : #Dsrpin ecito: # Nn oe # #Dpnece: eednis # "lr" ".." cak: 005 # #Cniuain ofgrto: # Nn oe # #Cmad: omns # hbtcak<aa -bidsakie oto dt uo lr dt> ul prlns u f aa # #Ato: uhr # aakiid jcsfe
  • 18. edit h b t s r p s j o uo-cit.sn add " l r . o f e cakcfe" run b n h b t i/uo say h b t c a k 1 2 3 4 5 uo lr
  • 19.
  • 20. HUBOT PERSISTANCE simple storage through h b t b a n uo.ri overloaded by redis-brain, mongo-brain, etc. (you can find these in hubot-scripts or write your own)
  • 21. You can save any arbitrary data in the brain. #yumywn t wi utltebanhsbe iiilzd o a at o at ni h ri a en ntaie #adteei adtbs cneto n hr s aaae oncin rbtbano 'odd,- oo.ri.n lae' > rbtbanlsAcse =nwDt( oo.ri.atcesd e ae) rbtbansaul =1 oo.ri.egls 2 rbtbanfoes={pnis tu,dfois fle} oo.ri.lwr ase: re afdl: as #hbtbanrn o eet uo ri us n vns rbtbanei 'ae oo.ri.mt sv'
  • 22. HUBOT HTTP LISTENER CREATE AND EDIT SRPSSYCFE CIT/A.OFE
  • 23. qeytig=rqie'ursrn' ursrn eur(qeytig) mdl.xot =(oo)- oueeprs rbt > rbtrue.e "hbtsy,(e,rs - oo.otrgt /uo/a" rq e) > qey=qeytigprerq_asdr.ur) ur ursrn.as(e.preUlqey msae=qeymsae esg ur.esg ue ={ sr } ue.om=qeyro i qeyro srro ur.om f ur.om rbtsn(sr msae oo.edue, esg) rsed"ad#msae" e.n si {esg}
  • 24. edit p c a e j o to include akg.sn " u r s r n " " = 0 1 0 in the dependencies qeytig: > .." run n m i s a l p ntl run b n h b t i/uo visit l c l o t 8 8 / a ? e s g = e l oahs:00symsaehlo
  • 25. DEPLOYMENT 99 times out of 100, you'll probably just deploy to Heroku h b t - creates a Heroku P o f l for you uo c rcie run H r k c e t eou rae deploy with g t p s h r k m s e i uh eou atr start with h r k p : c l w b 1 eou ssae e= (you'll only have to run p : c l this the first time) ssae
  • 26. CHAT ADAPTERS Hubot ships with a Campfire adapter. You can get more from hubot-scripts. Assuming Heroku deployment, run Hrk cni:d eou ofgad HBTCMFR_OE=ert UO_APIETKNsce HBTCMFR_OM=2,5 UO_APIEROS1346 HBTCMFR_CON=hbt UO_APIEACUT"uo"