File: cadabra-jupyter-main.cc

package info (click to toggle)
cadabra2 2.4.3.2-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 78,732 kB
  • sloc: ansic: 133,450; cpp: 92,064; python: 1,530; javascript: 203; sh: 184; xml: 182; objc: 53; makefile: 51
file content (20 lines) | stat: -rw-r--r-- 611 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include <iostream>
#include <memory>

#include "cadabra-jupyter-kernel.hh"
#include "xeus/xkernel.hpp"
#include "xeus/xkernel_configuration.hpp"

int main(int argc, char* argv[])
	{
	std::string file_name = (argc == 1) ? "connection.json" : argv[2];
	xeus::xconfiguration config = xeus::load_configuration(file_name);

	using interpreter_ptr = std::unique_ptr<cadabra::CadabraJupyter>;
	interpreter_ptr interpreter = interpreter_ptr(new cadabra::CadabraJupyter());
	xeus::xkernel kernel(config, "kpeeters", std::move(interpreter));
	std::cout << "starting kernel" << std::endl;
	kernel.start();

	return 0;
	}