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
{ | |
"version": "2.0.0", | |
"tasks": [ | |
{ | |
"label": "Run My Shell Script", | |
"type": "shell", | |
"workingDirectory": "${workspaceFolder}", | |
"command": "./shell/vscode_onsave.sh", | |
"problemMatcher": [], | |
"group": { |
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
#!/bin/bash | |
echo "✅pre-push hook start at $(date)" | |
start_time=$(date +%s) | |
echo "🎉pre-push hook end at $(date) elapsed $(($(date +%s) - $start_time)) seconds" |
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
#!/bin/bash | |
source .env | |
source ./shell/logger.sh | |
log "✅post-push hook start at $(date)" | |
start_time=$(date +%s) | |
log "🎉post-push hook end at $(date) elapsed $(($(date +%s) - $start_time)) seconds" |
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
#!/bin/bash | |
echo "✅post-commit hook start at $(date)" | |
start_time=$(date +%s) | |
# 查看环境变量 | |
source .env | |
echo "👁️build_version: $build_version" | |
echo "👁️build_time: $build_time" |
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
#!/bin/bash | |
echo "✅post-push hook start at $(date)" | |
start_time=$(date +%s) | |
echo "🎉post-push hook end at $(date) elapsed $(($(date +%s) - $start_time)) seconds" |
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
#!/bin/bash | |
echo "✅pre-push hook start at $(date)" | |
start_time=$(date +%s) | |
echo "🎉pre-push hook end at $(date) elapsed $(($(date +%s) - $start_time)) seconds" |
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
#!/bin/bash | |
echo "✅post-commit hook start at $(date)" | |
start_time=$(date +%s) | |
# 查看环境变量 | |
source .env | |
echo "👁️build_version: $build_version" | |
echo "👁️build_time: $build_time" |
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
#!/bin/bash | |
echo "✅pre-commit hook start at $(date)" | |
start_time=$(date +%s) | |
# 添加环境变量 | |
source .env | |
echo "👁️build_version: $build_version" | |
echo "👁️build_time: $build_time" | |
# 将环境变量的第三位加1 |
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
#!/bin/bash | |
echo "✅post-commit hook start at $(date)" | |
start_time=$(date +%s) | |
# 查看环境变量 | |
source .env | |
echo "👁️build_version: $build_version" | |
echo "👁️build_time: $build_time" |
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
#!/bin/bash | |
echo "✅pre-commit hook start at $(date)" | |
start_time=$(date +%s) | |
# 添加环境变量 | |
source .env | |
echo "👁️build_version: $build_version" | |
echo "👁️build_time: $build_time" | |
# 将环境变量的第三位加1 | |
build_version=$(echo $build_version | awk -F. '{$NF = $NF + 1;} 1' | sed 's/ /./g') |
NewerOlder