-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
64 changed files
with
768 additions
and
2,794 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
# bash | ||
# 运行 sh ./help/commit-template.sh | ||
# 脚本用于上传模板的修改,同时更新依赖,切换文件夹 | ||
|
||
# cd ~/Documents/eazytec/ecoder-basis-template | ||
# yarn run upgrade | ||
# git checkout master | ||
# git add * | ||
# git commit -m "更新依赖" | ||
# git push origin master | ||
|
||
cd ~/Documents/eazytec/ECoder | ||
|
||
# 这里需要用户的绝地地址,或者相对于当前所在的文件夹的地址 | ||
LOGFILE="/Users/qww/Documents/eazytec/ECoder/help/log/commit-log.txt" | ||
|
||
function logGenerate() { | ||
echo $PWD | ||
echo $(dirname $0) | ||
echo "-------------------------------" >>$LOGFILE | ||
echo $1 >>$LOGFILE | ||
echo $2 >>$LOGFILE | ||
echo "-------------------------------" >>$LOGFILE | ||
} | ||
|
||
function runGitBash() { | ||
git checkout master | ||
git add * | ||
git commit -m "upgrade: 更新依赖" | ||
git push origin master | ||
} | ||
|
||
function upgrade() { | ||
datetimeStart=$(date '+%Y-%m-%d %H:%M:%S') | ||
cmd = $(yarn run upgrade) | ||
log = ${cmd} | ||
logGenerate $1 $datetimeStart | ||
} | ||
|
||
function runTask() { | ||
cd ~/Documents/eazytec/$1 | ||
git pull | ||
upgrade $folder | ||
runGitBash | ||
} | ||
|
||
# 函数的参数不通过()传递,通过紧跟的变量传递,通过$N来获取 | ||
function templateTask() { | ||
# 读取文件夹$1,并遍历 | ||
for folder in $(ls $1); do | ||
# 判断如果folder包含$2就输出 | ||
if [[ $folder =~ $2 ]]; then | ||
# 输出带颜色的字体 | ||
runTask $folder | ||
echo "\033[1;35m $folder end \033[0m" | ||
fi | ||
done | ||
} | ||
# 定义根节点变量,并传入函数getdir,通过$1接收参数 | ||
root_dir="../" | ||
key_word="ecoder-" | ||
templateTask $root_dir $key_word |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<title></title> | ||
</head> | ||
<style type="text/css"> | ||
body { | ||
padding: 0; | ||
margin: 0; | ||
height: 100%; /*定义页面整体高度为100%,重要*/ | ||
} | ||
.container { | ||
display: flex; /*父元素的定义为flex布局*/ | ||
width: 100%; | ||
height: 500px; /*这里也要定义,重要*/ | ||
flex-direction: column; /*定义排列方向为竖排*/ | ||
} | ||
.header { | ||
height: 100px; /*头部固定高度*/ | ||
background: red; | ||
} | ||
.footer { | ||
height: 100px; /*尾部固定高度*/ | ||
background: yellow; | ||
} | ||
.main { | ||
background: #ccc; | ||
flex: 1; /*中间分配剩下的所有空间*/ | ||
overflow: auto; | ||
} | ||
</style> | ||
<body> | ||
<div class="container"> | ||
<div class="header">我是头部</div> | ||
<div class="main"> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
我是flex布局实现的中间自适应<br />我是flex布局实现的中间自适应<br /> | ||
</div> | ||
<div class="footer">我是尾部</div> | ||
</div> | ||
</body> | ||
</html> |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.