it’s the tools
I was checking out the source code for wscat and noticed it looked like a trivial port to Perl. Then I searched ddg for "wscat perl" and the first result took me to Net::WebSocket where the changes mention a "wscat.pl demo script" (which it doesn't install, wtf). After installing Net::WebSocket the script wscat.pl failed to run because IO::Events was not installed. After installing IO::Events it still failed because MockReader was not installed. Trying to install MockReader seemed to simply reinstall Net::WebSocket and didn't fix the problem. Then I noticed @INC was modified by wscat.pl so I had to mkdir 'lib' and put MockReader.pm in a /lib relative to the location of wscat.pl. After the hassle, which only took a minute or two, the wscat.pl demo script appears to function and the example given for the javascript version worked perfectly! I guess it would be a good idea for someone to clean up the installation mess and release something useful like App::wscat so you can use Perl!
> wscat.pl ws://echo.websocket.org
> hi there
> hi there
> are you a happy parrot?
> are you a happy parrot?
https://github.com/websockets/wscat
https://metacpan.org/source/FELIPE/Net-WebSocket-0.21/demo/wscat.pl
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|