Magellan Linux

Diff of /mcore-src/trunk/mcore-tools/src/mcored.in

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

mcore-src/trunk/mcore-tools/daemon/client/mcored.sh revision 2044 by niro, Wed May 8 11:04:43 2013 UTC mcore-src/trunk/mcore-tools/src/mcored.in revision 2258 by niro, Mon Jan 13 14:25:18 2014 UTC
# Line 1  Line 1 
1  #!/bin/bash  #!/bin/bash
2    
3  MCLIBDIR="/usr/lib/mcored"  MCORE_LIBDIR="@@MCORE_LIBDIR@@"
4    
5    # respect system env (proxy settings etc)
6    if [ -e @@SYSCONFDIR@@/profile ]
7    then
8     source @@SYSCONFDIR@@/profile
9    fi
10    
11  # globals  # globals
12  source ${MCLIBDIR}/include/daemon.global.class  # include function comes with common.global class
13  source ${MCLIBDIR}/include/sessionauth.global.class  source ${MCORE_LIBDIR}/include/common.global.class
14  #source ${MCLIBDIR}/include/mysqlfunctions.global.class  include ${MCORE_LIBDIR}/include/daemon.global.class
15  source ${MCLIBDIR}/include/hwdetection.global.class  include ${MCORE_LIBDIR}/include/sessionauth.global.class
16    #include ${MCORE_LIBDIR}/include/mysqlfunctions.global.class
17    include ${MCORE_LIBDIR}/include/hwdetection.global.class
18    
19  # load client classes plugins  # load client classes plugins
20  load_client_classes  load_client_classes
21    
22  # config settings  # config settings
23  source /etc/mcore/config.rc  include @@SYSCONFDIR@@/mcore/mcore.conf
24  #source /etc/mcore/serial  #source @@SYSCONFDIR@@/mcore/serial
25    
26  # import_hardware_resource()  # import_hardware_resource()
27  # {  # {
# Line 52  QUIET="false" Line 60  QUIET="false"
60  run=run  run=run
61  valid_session=no  valid_session=no
62    
63    # tell what we are
64    echo "Connected to $(print_version)"
65    
66  while [[ ${run} = run ]]  while [[ ${run} = run ]]
67  do  do
68   read line   read line
# Line 74  do Line 85  do
85   webcrlf) export WEBCRLF="true" ;;   webcrlf) export WEBCRLF="true" ;;
86   quiet) export QUIET="true" ;;   quiet) export QUIET="true" ;;
87   # version does not need auth   # version does not need auth
88   version) echo "${VERSION}" ;;   version) print_version ;;
89   help*)   help*)
90   if valid_session   if valid_session
91   then   then
# Line 91  do Line 102  do
102   ;;   ;;
103    
104   *)   *)
105   mecho "Unkown command '${line}'"   mecho "Unknown command '${line}'"
106   mecho "Type 'help' for more information."   mecho "Type 'help' for more information."
107   #echo "$line" >> /root/lala.log   #echo "$line" >> /root/lala.log
108   ;;   ;;

Legend:
Removed from v.2044  
changed lines
  Added in v.2258