From ddcc3dd9837dfe1c16826d668ad380cb89e3e98c Mon Sep 17 00:00:00 2001 From: Thomas Kluyver Date: Fri, 26 Oct 2018 13:45:29 +0100 Subject: [PATCH] Display kernel type ID alongside display name --- notebook/static/notebook/js/kernelselector.js | 12 ++++++++---- notebook/static/tree/js/newnotebook.js | 2 +- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/notebook/static/notebook/js/kernelselector.js b/notebook/static/notebook/js/kernelselector.js index 990b8e1f8b..41c4ee4bcc 100644 --- a/notebook/static/notebook/js/kernelselector.js +++ b/notebook/static/notebook/js/kernelselector.js @@ -74,7 +74,7 @@ define([ .click( function () { that.set_kernel(ks.name); }) - .text(ks.spec.display_name) + .text(ks.spec.display_name + " (" + ks.name + ")") ) ); // Create the File > New Notebook submenu @@ -86,7 +86,7 @@ define([ .click( function () { that.new_notebook(ks.name); }) - .text(ks.spec.display_name) + .text(ks.spec.display_name + " (" + ks.name + ")") ) ); @@ -262,13 +262,17 @@ define([ } names.map(function (name) { var ks = that.kernelspecs[name]; + var display_txt = ks.name; + if (ks.spec.display_name) { + display_txt = ks.spec.display_name + " (" + ks.name + ")" + } select.append( - $('