Reputation: 81
I read the official tutorials,Odoo's scaffolding can setup a basic module. To quickly get started simply invoke:
$ ./odoo-bin scaffold Academy my-modules
I tried it but it didn't work,Because it remind Odoo-bin is not a command
I have entered the odoo installation directory
Upvotes: 5
Views: 15860
Reputation: 1
For Windows OS, use cmd below:
F:\Source\Odoo\python\python.exe .\odoo-bin scaffold om_odoo_inheritence F:\Source\Odoo\server\custom_addons
Which is:
Upvotes: 0
Reputation: 1
Solution
PD: if You prefer define other place to put your <custon_module> You can do it ofbthis way: python odoo-bin scaffold "<name_custom_module> dir/route-that-you-prefer"
Upvotes: 0
Reputation: 129
Maybe this will help someone.
After googling around I found this post.
I too had issue with using scaffold command in windows and couldn't understand what is wrong with it, until I figure it out.
My issue was that I was getting error
PermissionError: [WinError 5] Access is denied: 'C:\Program Files\
This is basically telling you that permission is denied as you cannot create inside of the above mentioned path. This got me to thinking that I have not pointed to the right path and my solution below worked.
Good Luck
I presume that your project is up and running / installed correctly, so if so this will work.
python odoo-bin scaffold yourmodulename ./addons
I tried this in Git Bash and Command Prompt and it works.
Upvotes: 1
Reputation: 64
I have created the summarize of all the process of command to create the module and change the addon repository.
Run your CMD as administration and copy and paste the command below and hit enter.
"C:\Program Files (x86)\Odoo 12.0\python\python.exe" "C:\Program Files (x86)\Odoo 12.0\server\odoo-bin" scaffold manageasset "C:\Users\User\Desktop\custom_addons"
<==============================================>
Command explanation:
"C:\Program Files (x86)\Odoo 12.0\python\python.exe" "C:\Program Files (x86)\Odoo 12.0\server\odoo-bin": this command is the respository of your odoo12 instalation -It used to be odoo-bin.
"scaffold": will create the module.
"manageasset": name of your module.
"C:\Users\User\Desktop\custom_addons": your custom module directory. By default It is "C:\Program Files (x86)\Odoo 12.0\server\odoo\addons".
<==============================================>
Incase you don't know how to change the addon directory follow this:
<====================The end========================> Link to github gist
Upvotes: 0
Reputation: 21
I used the following method for Odoo 12.0 installed on Windows. First run command prompt as administrator. Then use cd to change directory. Then execute python, navigate to odoo-bin, call scaffold with parameters 1)module name and 2)qualified install location. (openacademy is the name of the module from the tutorial)
C:\WINDOWS\system32>cd C:\Program Files (x86)\Odoo 12.0\python
C:\Program Files (x86)\Odoo 12.0\python>python ..\server\odoo-bin scaffold openacademy ..\server\odoo\addons
Upvotes: 2
Reputation: 166
Use this command on the command-line:
"<Path_to_python.exe in the Odoo folder>" "<Path_to_odoo-bin>" scaffold "<Path_to_addons_folder>"
E.g.:
"c:\Program Files (x86)\Odoo 11.0\python\python.exe" "C:\Program Files (x86)\Odoo 11.0\server\odoo-bin" scaffold <module name here> "C:\Program Files (x86)\Odoo 11.0\server\odoo\addons"
Upvotes: 15