Bash Script Structure: Difference between revisions

From Chorke Wiki
Jump to navigation Jump to search
Line 40: Line 40:
==Bash for Shahed==
==Bash for Shahed==


# bash settings/initialization
<syntaxhighlight lang="bash">
BASH_HOME=$HOME/.shahed/var/bash
# locale bash script path setting
BASH_PATH=$BASH_HOME/php/biz/bash
BASH_HOME=$HOME/.shahed/var/bash
BASH_SITE=http://cdn.chorke.org/bash
BASH_PATH=$BASH_HOME/php/biz/site


# bash script download/copy
# remote bash script path setting
curl $BASH_SITE/php/init>$BASH_PATH/init
BASH_BASE=http://cdn.shahed.biz/bash
curl $BASH_SITE/php/make>$BASH_PATH/make
BASH_SITE=$BASH_BASE/php/site
curl $BASH_SITE/php/make>$BASH_PATH/make/option
 
curl $BASH_SITE/php/pull>$BASH_PATH/pull
# remote bash scripts download to locale
curl $BASH_SITE/php/push>$BASH_PATH/push
for b in init make pick/make pull push sync;do\
curl $BASH_SITE/php/sync>$BASH_PATH/sync
    curl "$BASH_SITE/$b>$BASH_PATH/$b";\
done
</syntaxhighlight>


  ~/.shahed/
  ~/.shahed/
Line 59: Line 61:
           └─ php/
           └─ php/
             └─ biz/
             └─ biz/
                 ├─ site/
                 ├─ bash/
                 └─ bash/
                 └─ site/
                   ├─ init
                   ├─ init
                   ├─ make
                   ├─ make

Revision as of 06:31, 10 January 2018

Bash for Chorke

# locale bash script path setting
BASH_HOME=$HOME/.chorke/var/bash
BASH_PATH=$BASH_HOME/java/org/init

# remote bash script path setting
BASH_BASE=http://cdn.chorke.org/bash
BASH_SITE=$BASH_BASE/java/init

# remote bash scripts download to locale
for b in init make pick/make pull push sync;do\
    curl "$BASH_SITE/$b>$BASH_PATH/$b";\
done
~/.chorke/
   ├─ tmp/
   └─ var/
      └─ bash/
         └─ java/
            ├─ com/
            │  ├─ ebis/
            │  └─ ehis/
            └─ org/
               ├─ amqp/
               ├─ core/
               ├─ ecma/
               └─ init/
                  ├─ init
                  ├─ make
                  ├─ make/all
                  ├─ pull
                  ├─ push
                  └─ sync

Bash for Shahed

# locale bash script path setting
BASH_HOME=$HOME/.shahed/var/bash
BASH_PATH=$BASH_HOME/php/biz/site

# remote bash script path setting
BASH_BASE=http://cdn.shahed.biz/bash
BASH_SITE=$BASH_BASE/php/site

# remote bash scripts download to locale
for b in init make pick/make pull push sync;do\
    curl "$BASH_SITE/$b>$BASH_PATH/$b";\
done
~/.shahed/
   ├─ tmp/
   └─ var/
      └─ bash/
         └─ php/
            └─ biz/
               ├─ bash/
               └─ site/
                  ├─ init
                  ├─ make
                  ├─ make/all
                  ├─ pull
                  ├─ push
                  └─ sync