Skip to content
This repository was archived by the owner on Oct 14, 2020. It is now read-only.

Listen.js fix/Readme #453

Merged
merged 3 commits into from
Jul 13, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,18 +73,20 @@ Many languages are currently supported in various states of completeness. This l
| Language | Version | Basic Run | Project Mode | Test Integration | Codewars | Qualified | Docker Image | Examples | Notes |
|----------------|---------------|------------|--------------|------------------|----------------|----------------|--------------|---------------| ------------------------------------------------------------------------|
| Assembly (GAS) | | !!! | | | | | systems-runner | | Travis is failing, tests pass locally |
| Bash | | ✓ | ✓ | | Kumite Only | | * | | |
| Bash | | ✓ | ✓ | rspec | rspec | rspec | ruby-runner | | |
| Brainf**k | 20041219 | ✓ | ✓ | cw-2 | cw-2 | | esolangs-runner | | |
| C | Clang 3.6/C11 | ✓ | | criterion | criterion | | systems-runner | | |
| Clojure | 1.6.0 | ✓ | | clojure.test | clojure.test | clojure.test | jvm-runner | clojure.test | |
| CoffeeScript | 1.10.0 | ✓ | | cw-2 | cw-2 | cw-2 | node-runner | cw-2 | |
| C++ | 14 | ✓ | | igloo | igloo | | systems-runner | | |
| C++ | 14 | ✓ | | igloo | igloo | igloo | systems-runner | | |
| C# | Mono 4.8 | ✓ | ✓ | nunit | nunit | nunit | dotnet-runner | nunit | |
| Chapel | 1.15.0 | ✓ | ✓ | cw-2 | cw-2 | | chapel-runner | cw-2 | |
| Crystal | 0.21.1 | ✓ | | spec | spec | spec | crystal-runner | spec | |
| Dart | 1.16.1 | ✓ | | test | Kumite Only | | dart-runner | test | |
| Elixir | 1.2.4 | ✓ | | exunit | exunit | | erlang-runner | | |
| Erlang | 18 | ✓ | | | | | erlang-runner | | |
| F# | 4.1 | ✓ | | fuchu | fuchu | | dotnet-runner | Fuchu | Tests should be placed in a module called "Tests", in a Fuchu testList |
| Go | 1.8 | ✓ | | ginkgo | ginkgo | | go-runner | ginkgo | |
| Go | 1.8 | ✓ | | ginkgo | ginkgo | ginkgo | go-runner | ginkgo | |
| Groovy | | ✓ | | | Kumite Only | | jvm-runner | | |
| Haskell | 7.6.3 | ✓ | | hspec!!! | hspec | hspec | haskell-runner | hspec | An older version is running on CW & Qualified that is fully functional |
| Java | 1.8.0_91 | ✓ | | junit | Yes | Yes | jvm-runner | junit | |
Expand Down
9 changes: 5 additions & 4 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -202,16 +202,17 @@ services:
entrypoint: ''
command: bash

# LANGUAGE SPECIFIC HELPERS
javascript:
image: codewars/node-runner
esolangs-runner:
image: codewars/esolangs-runner
volumes:
- ./lib:/runner/lib
- ./examples:/runner/examples
- ./frameworks:/runner/frameworks
- ./test:/runner/test
entrypoint: 'node run -l javascript'
entrypoint: ''
command: bash

# LANGUAGE SPECIFIC HELPERS
javascript_test:
image: codewars/node-runner
environment:
Expand Down
8 changes: 6 additions & 2 deletions listen.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
// this file is used to keep a image alive so that it can be pre-warmed and communicated with.
const net = require('net'),
execSync = require('child_process').execSync;
execSync = require('child_process').execSync,
fs = require('fs');

// if the script is available, it will call it
console.log(execSync('sh /runner/prewarm.sh').toString());
if (fs.existsSync('/runner/prewarm.sh')) {
console.log(execSync('sh /runner/prewarm.sh').toString());
}


// Creates a new TCP server. The handler argument is automatically set as a listener for the 'connection' event
var server = net.createServer(function(socket) {
Expand Down