Codegen Problem

thread: 6 messages  |  last: about 2 years ago  |  started: thursday, november 26, 2009, 10:11 am pst


#1  |  Leonardo (Minas Gerais) Brazil
Thursday, November 26, 2009, 10:11 AM PST

Hello I'm thinking of migrating qcodo the 0.3.x to 0.4.x, however I am struggling to generate code. How to generate the code in this new version, because I have to run an executable file. Bat?

I did this but did not generate anything

Att

#2  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Monday, November 30, 2009, 1:43 PM PST

assuming that your qcodo.bat file is configured properly (e.g. it has the correct path to your php.exe), then all you need to do is ensure that your codegen_settings.xml file is stored at c:\path\to\cli\settings\codegen.xml and then run

c:\path\to\cli\qcodo.bat codegen

Please post if you continue running into issues.

#3  |  Patrick Ranger (Montreal, Qc) Canada
Thursday, December 17, 2009, 1:40 PM PST

I have the same problem and am unable to find my way through. I updated the path to php.exe in qcodo.bat (i'm on Windows), I renamed codegen.xml-dist to codegen.xml and when I run qcodo.bat codegen, I get “error: the script 'codegen' does not exist.”. I also tried copying “codegen.cli.php” from _core directly in the scripts directory without any luck (don't know if that was necessary). What did I miss?

#4  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Thursday, December 17, 2009, 10:55 PM PST

What shows up when you run
c:\path\to\cli\qcodo.bat
by itself?

#5  |  Patrick Ranger (Montreal, Qc) Canada
Friday, December 18, 2009, 6:00 AM PST

It shows documentation on the script :

Qcodo CLI Runner v0.4.8
usage: qcodo SCRIPT [SCRIPT-SPECIFIC ARGS]

required parameters:
  SCRIPT         the .cli.php script name inside the cli/sc
                 that you wish to run

the following SCRIPTs are included with the Qcodo distribut
  codegen        Code generates your ORM-layer
  qcodo-updater  Updates your installed Qcodo framework to
  qpm-download   Download and installs an external QPM pack
  qpm-upload     Packages custom code you wrote into a QPM

Other custom scripts can be created as well.
See "__DEVTOOLS_CLI__/scripts/_README.txt" for more info
.bc
#6  |  Patrick Ranger (Montreal, Qc) Canada
Friday, December 18, 2009, 8:13 AM PST

OK I found the problem. My _DEVTOOLS_CLI_ path was not set correctly in my configuration.inc.php file. Sorry about that.



Copyright © 2005 - 2012, Quasidea Development, LLC
This open-source framework for PHP is released under the terms of The MIT License.