Rantanen / node-mumble

Mumble client in Node.js
MIT License
155 stars 48 forks source link

Fixes user.inputStream() and automates typescript declaration file generation #111

Closed ppacher closed 5 years ago

ppacher commented 5 years ago

As discussed in #110, this pull request fixes the user.inputStream() method and automates the generation of TypeScript declaration files (it should also fix the eslint errors on travis).

It also adds a few new devDependecies for typescript (validating the generated declaration file), jsdoc and @otris/jsdoc-tsd for generating the declaration file.

Unfortunately https://github.com/otris/jsdoc-tsd does not yet support JSDoc's @extends so I need to create a script to fix the declaration file (i.e. MumbeInputStream and MumbleOutputStream correctly extend stream.Writable and stream.Readable). The script requires grep and sed to be installed when generating the typings (tried to avoid that but didn't found a reasonable way).

I'd be fine to help keeping them up-to-date.

ppacher commented 5 years ago

Please wait until I've been able to actually test the type definitions. I'll try to do that in the evening/tomorrow but I'm confident that they should work.

codecov-io commented 5 years ago

Codecov Report

Merging #111 into master will not change coverage. The diff coverage is 0%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #111   +/-   ##
=======================================
  Coverage   21.05%   21.05%           
=======================================
  Files          12       12           
  Lines        1121     1121           
  Branches      184      184           
=======================================
  Hits          236      236           
  Misses        885      885
Impacted Files Coverage Δ
lib/MumbleConnection.js 13.56% <ø> (ø) :arrow_up:
lib/MumbleInputStream.js 16.25% <ø> (ø) :arrow_up:
lib/util.js 20.37% <ø> (ø) :arrow_up:
lib/Channel.js 23.59% <ø> (ø) :arrow_up:
lib/MumbleConnectionManager.js 51.85% <ø> (ø) :arrow_up:
lib/MumbleClient.js 21.21% <ø> (ø) :arrow_up:
lib/User.js 25.53% <0%> (ø) :arrow_up:
lib/MumbleSocket.js 17.07% <0%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update ce09f35...b0754f5. Read the comment docs.

ppacher commented 5 years ago

Sorry but I'm closing this due to inactivity on my side. If I find some time to work on that again I'll file a new one.