Zurmo - - 命令行工具

一:简介数据库

1. Zurmo 提供了一个命令行工具,以便于更新版本,修改密码,安装以及更新数据库模式等等功能的快捷操做。文件位于 ..app/protected/commands/ 下。windows

二:详解app

  1. Zurmo一共有 15 条 zurmoc 命令,分别是:
- help             查看帮助
- changepassword   修改密码
- database 
- elevate 
- email 
- import           导入数据
- install          安装
- installlanguage 
- jobmanager 
- lesscompiler 
- managemetadata 
- resetstuckjobs 
- setmaintenancemode 
- updateschema     更新数据库模式 
- upgradezurmo     更新版本

PS:上面只是罗列出全部的命令,可是是不完整的,只是命令的一部分。less

  1. 下面以 updateschema 命令为例,完整的用法是:
updateschema

USAGE
  zurmoc updateSchema <username> <overwriteExistingReadTables>
DESCRIPTION 
This command runs an update on the database schema. It calls the 
InstallUtil::runAutoBuildFromUpdateSchemaCommand.

PARAMETERS

username: username to log in as and run the import processes. Typically ‘super’. 
This user must be a super administrator.
overwriteExistingReadTables: If set to 1 all read tables would be regenerated, which could be a time consuming process. 
If not set, or set to 0, any existing read tables would be skipped. 
Defaults to 0.
zurmoc updateSchema <username> [0/1]
  • 这个命令是用来更新数据库模式,就是改了代码中关于model属性(之后介绍),能够直接修改数据库。而没必要手动修改数据库。
  • 参数<username> 就是用户名,是超级管理员的权限的用户名
  • 参数<overwriteExistingReadTables> 是关于数据库表更新的时候,用于筛选的条件,具体内容之后再介绍,或者看博客,在最下面有介绍。

PS:这些命令在windows上使用的时候,大小写应该是不区分的,我试过几条命令是不区分的,可是没有所有都试过。工具

三:剩下的14条命令就不详细说了,能够本身去看代码,也能够去下载文档来看,里面有全部命令的用法介绍。ui

PS:最经常使用的是 udpateschema 命令,要掌握。对于开发的效率有很大的帮助。.net

若有不对请指正!命令行