hubotã®scriptãå帰çã«èªãã&ãhubot-ircã§noticeçºè¨ããã
ã¯ã¦ãªãã¤ã¢ãªã¼ã®ãã¹ããã¦ãhubotã§è©°ã¾ã£ãé¨åï¼è§£æ±ºããé¨å
hubot scriptsãã£ã¬ã¯ããªã®ã¹ã¯ãªãããé層åãã¦èªã¿è¾¼ã¿ãã
hubotã®ã¹ã¯ãªããã¯æ±ºãæã¡ã«ãªã£ã¦ãã./scriptsã./src/scriptsããèªã¾ããã
ãããä¸åã®ãã©ã«ãã«ã¶ã£è¾¼ãã ãããããããªããªã£ã¦ãã¾ãã®ã§ããã£ã¨æ¸ãã¦ã¿ãã
scriptã®ä¸ã§èªã¾ããã¨ããããæ¹ã§è§£æ±ºã
__dirnameã¯node.jsçãªãã®ã¹ã¯ãªããã®ãããã©ã«ããå·®ã示ãã¦ããã
globã¨ããããã±ã¼ã¸ãå©ç¨ãã¦ããã®ã§
npm install glob
ãããå¿
è¦ã¢ãª
hubot-ircã§noticeçºè¨ããããï¼èæ¥ç·¨ï¼
hubotã«ircçºè¨ããããhubot-ircã ããnoticeçºè¨ã¯ããã©ã«ãã§ã¯ã§ããªãã
çµæ§è²ã ãªäººãæ©ãã§ãã¿ããã§forkãããæ¸ãæããããã¦è§£æ±ºãã¦ããããæ¸ãæãããããã®ãå«ã ã£ãã®ã§ã¡ãã£ã¨èã£ã½ãããæ¹ã ãã©ãããªè§£æ±ºããã¦ã¿ãã hubot scriptã¨ãã¦èªã¿è¾¼ãã§ãã¾ããhubot-ircå ã®bot(å®ä½ã¯ircã¨ããnodeã®ircçºè¨ç¨ã¢ã¸ã¥ã¼ã«)ã®çºè¨(say)ã³ãã³ããä¸æ¸ãã
nickServer使ã£ã¦ããé¨åã§sayãå¼ã°ããã®ã§nickServer使ã£ã¦ããå ´åã¯ä½¿ããªããã
èªåã®ç°å¢ã§ã¯ããããå¿ è¦ã®ããircãµã¼ãã¼ã¯ç¡ãã®ã§ã©ããªããã¯æªæ¤è¨¼ã»ã»ã»
forkãã¦æ¸ãæããå ´åã¨ããã¹ã¦ã®å©ç¹ã¨ãã¦ã¯hubot-ircå´ã«æ´æ°ããã£ã¦ãåºæ¬çã«ã¯è¿½å¾ã§ããã£ã¦ãã¨ããã