Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Can we use Slack on Vim?

26b059a7fa4d54ae985894ab232ea101?s=47 higashi
November 03, 2019
130

Can we use Slack on Vim?

I announced this slide in VimConf 2019 LT session.

26b059a7fa4d54ae985894ab232ea101?s=128

higashi

November 03, 2019
Tweet

Transcript

  1. Can we use Slack on Vim? in VimConf 2019 LT

    Session @higashi136_2
  2. My Profile Name : higashi Usually : Student in Okinawa

    Favorite Language : VimScript, Dlang, Golang Like : Vim, Linux GitHub : higashi000 Twitter : @higashi136_2
  3. Do you want to use Slack on Vim?

  4. Yes!!

  5. If we can use Slack on Vim... ・Post message from

    Vim ・Check channel history from Vim ・Registration reminder from Vim etc...
  6. Let’s Implementation ・higashi000/sarahck.vim ・higashi000/sleahck ・higashi000/sleahck.vim

  7. How to use Slack on Vim ・Slack API ・Slack Legacy

    Token ・HTTP requests using Python or Ruby or etc… ・HTTP requests using webapi-vim created by Mr.mattn
  8. Implementation on Python ・Use requests module and Vim module ・User

    must install the modules →
  9. Implementation on Python ・Use requests module and Vim module ・User

    must install the modules →Can I not implement it only in VimScript?
  10. Implementation on webapi-vim ・Use mattn/webapi-vim ・User only needed to install

    Vim Plugin →
  11. Implementation on webapi-vim ・Use mattn/webapi-vim ・User only needed to install

    Vim Plugin →higashi000/sarahck.vim
  12. Post message from sarahck.vim

  13. Check Channel List and History from sarahck.vim

  14. Isssue ・Delay until message display

  15. Isssue ・Delay until message display I want to display it

    earlier
  16. Before HTTP requests Response GET /api/channels.history {“ok”:true}

  17. Proposal local cache server {“ok”:true} Response GET Request to Channel

    History Request cache Return cache
  18. Implemented ・higashi000/sleahck ・higashi000/sleahck.vim

  19. higashi000/sleahck ・”sleahck” implemented in Golang ・Use gin-gonic/gin and nlopes/slack ・Update

    messages every 1minute
  20. higashi000/sleahck.vim ・”sleahck.vim” implemented in  VimScript and mattn/webapi-vim ・Reference of local

    cache from Vim ・A function in sarahck.vim formerly →
  21. higashi000/sleahck.vim ・”sleahck.vim” implemented in  VimScript and mattn/webapi-vim ・Reference of local

    cache from Vim ・A function in sarahck.vim formerly → Structure is different, separated from sarahck.vim.
  22. Check Channel List and History from sleahck.vim

  23. Summary Can we use Slack on Vim? →

  24. Summary Can we use Slack on Vim? →Yes!!

  25. Summary But, I can’t display the images due to my

    lack of my knowledge Either cannot display reaction and cannot enter and leave the channel
  26. Summary But, I can’t display the images due to my

    lack of my knowledge Either cannot display reaction and cannot enter and leave the channel Future task
  27. Thank you for listening to my LT!!