RE : run python script from command line

ls://dev.artenum.com/projects/jyconsole/forum/9c92a80ac0a80028005702783a00f929/aff196bac0a800280062ec87612afcd0

RE : run python script from command line
Thanks for your support,

Sorry for my answear a bite late but I was quite busy lately...

It's possible to run some setup at the begining to do so you will have to do something like that.

JyConsole consolePython = new JyConsole();
// load a file 
consolePython.executePythonFile(new File("setup.py"));

// add a variable inside a console consolePython.getPythonInterpreter().set("console", consolePython);

JFrame f = new JFrame("frame title"); f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); f.getContentPane().add(consolePython, BorderLayout.CENTER); f.setSize(600, 400); f.setLocationRelativeTo(null); f.setVisible(true);

posted by Jourdain Sebastien at Apr 19, 2006 4:19 AM

Decorated version - Feeds - LibreSource