NEW Do not use Function Aliases
This commit is contained in:
parent
00496cd49e
commit
8a022fb19d
@ -1,6 +1,7 @@
|
|||||||
#!/usr/bin/env php
|
#!/usr/bin/env php
|
||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
|
* Copyright (C) 2016 Juanjo Menent <jmenent@2byte.es>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -56,7 +57,7 @@ $error=0;
|
|||||||
|
|
||||||
@set_time_limit(0);
|
@set_time_limit(0);
|
||||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||||
dol_syslog($script_file." launched with arg ".join(',',$argv));
|
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||||
|
|
||||||
$mode = $argv[1];
|
$mode = $argv[1];
|
||||||
$filepath = $argv[2];
|
$filepath = $argv[2];
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
#!/usr/bin/env php
|
#!/usr/bin/env php
|
||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
|
* Copyright (C) 2016 Juanjo Menent <jmenent@2byte.es>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -56,7 +57,7 @@ $error=0;
|
|||||||
|
|
||||||
@set_time_limit(0);
|
@set_time_limit(0);
|
||||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||||
dol_syslog($script_file." launched with arg ".join(',',$argv));
|
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||||
|
|
||||||
$mode = $argv[1];
|
$mode = $argv[1];
|
||||||
$filepath = $argv[2];
|
$filepath = $argv[2];
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
#!/usr/bin/env php
|
#!/usr/bin/env php
|
||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
|
* Copyright (C) 2016 Juanjo Menent <jmenent@2byte.es>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -56,7 +57,7 @@ $error=0;
|
|||||||
|
|
||||||
@set_time_limit(0);
|
@set_time_limit(0);
|
||||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||||
dol_syslog($script_file." launched with arg ".join(',',$argv));
|
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||||
|
|
||||||
$mode = $argv[1];
|
$mode = $argv[1];
|
||||||
$filepath = $argv[2];
|
$filepath = $argv[2];
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env php
|
#!/usr/bin/env php
|
||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
*
|
* Copyright (C) 2016 Juanjo Menent <jmenent@2byte.es>
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation; either version 3 of the License, or
|
* the Free Software Foundation; either version 3 of the License, or
|
||||||
@ -146,7 +146,7 @@ $sqls=array(
|
|||||||
|
|
||||||
@set_time_limit(0);
|
@set_time_limit(0);
|
||||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||||
dol_syslog($script_file." launched with arg ".join(',',$argv));
|
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||||
|
|
||||||
$mode = $argv[1];
|
$mode = $argv[1];
|
||||||
$option = $argv[2];
|
$option = $argv[2];
|
||||||
@ -154,14 +154,14 @@ $option = $argv[2];
|
|||||||
if (empty($mode) || ! in_array($mode,array('test','confirm'))) {
|
if (empty($mode) || ! in_array($mode,array('test','confirm'))) {
|
||||||
print "Usage: $script_file (test|confirm) (all|option)\n";
|
print "Usage: $script_file (test|confirm) (all|option)\n";
|
||||||
print "\n";
|
print "\n";
|
||||||
print "option can be ".join(',',array_keys($sqls))."\n";
|
print "option can be ".implode(',',array_keys($sqls))."\n";
|
||||||
exit(-1);
|
exit(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($option) || ! in_array($option, array_merge(array('all'),array_keys($sqls))) ) {
|
if (empty($option) || ! in_array($option, array_merge(array('all'),array_keys($sqls))) ) {
|
||||||
print "Usage: $script_file (test|confirm) (all|option)\n";
|
print "Usage: $script_file (test|confirm) (all|option)\n";
|
||||||
print "\n";
|
print "\n";
|
||||||
print "option can be ".join(',',array_keys($sqls))."\n";
|
print "option can be ".implode(',',array_keys($sqls))."\n";
|
||||||
exit(-1);
|
exit(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user