gap-packages / JupyterKernel

Native Jupyter kernel for GAP
https://gap-packages.github.io/JupyterKernel/
BSD 3-Clause "New" or "Revised" License
19 stars 12 forks source link

Update bin/jupyter-kernel-gap #41

Closed fingolfin closed 6 years ago

fingolfin commented 6 years ago

To find GAP, we now proceed as follows: First, if $JUPYTER_GAP_EXECUTABLE is set, we use that. If not, then we check if $GAP is set and use that. If not, we try to use gap in the current path.

Also avoid the use of which, which is non-standard. Instead, just hard code the name gap, and don't bother performing any further checks (we don't validate the value of $JUPYTER_GAP_EXECUTABLE or $GAP either)

Finally, use exec to start GAP, replacing the shell, instead of creating a fresh process.

The script now passes the tests on https://www.shellcheck.net

pedritomelenas commented 6 years ago

Perfect! Thanks!

fingolfin commented 6 years ago

Tests fail, I'll look into it.

codecov[bot] commented 6 years ago

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@a522b85). Click here to learn what that means. The diff coverage is n/a.

@@           Coverage Diff           @@
##             master    #41   +/-   ##
=======================================
  Coverage          ?   8.2%           
=======================================
  Files             ?      9           
  Lines             ?    780           
  Branches          ?      0           
=======================================
  Hits              ?     64           
  Misses            ?    716           
  Partials          ?      0