<commit_before>#!/usr/bin/env bash

ROOT=$(pwd)
FIS_CONFIG_TEMPLATE="$ROOT/fis-conf.js"
FRAMEWORKS=(fis-plus)

if [ "$1" = "" ];then
    output="output"
else
    output=$1
fi

domain=
if [ "$2" != "dev" ]; then
    domain="\/fis-plus"
fi

isDev=

if [ "$2" = "dev" ]; then
    isDev="dev"
else
    export PATH=$ROOT/node_modules/.bin:$PATH
    export NODE_PATH=$ROOT/node_modules
fi

gitpush_gh () {
    framework=$1
    if [ "$isDev" = "" ]; then
        #AU
        git config --global user.email "<EMAIL>"
        git config --global user.name "xiangshouding"
        git config credential.helper "store --file=.git/credential"
        echo "https://${GH_TOKEN}:@github.com" > .git/credential
    fi
    git clone https://github.com/fex-team/${framework}.git
    cd "$framework"
    git checkout gh-pages
    rm -rf * #clear
    cp -rf ../output/* .
    git add *
    git commit -m 'update auto'
    git push origin gh-pages
    cd ..
    rm -rf "$framework"
}

for framework in $FRAMEWORKS; do
    echo $framework
    
    if [ "$isDev" = "" ]; then
        rm -rf $ROOT/doc
    fi
    
    cat $FIS_CONFIG_TEMPLATE | sed s/{%FRAMEWORK%}/${framework}/g > fis-conf-${framework}.js
    cat fis-conf-${framework}.js | sed s/{%DOMAIN%}/${domain}/g > fis-conf-${framework}_tmp.js
    mv fis-conf-${framework}_tmp.js fis-conf-${framework}.js
    
    if [ "$isDev" = "" ]; then
        git clone https://github.com/fex-team/${framework}.wiki.git $ROOT/doc
    fi
    
    fis release -cmDd $output -f fis-conf-${framework}.js
    if [ "$?" = "0" -a -d "./output" ]; then
        gitpush_gh "$framework"
        rm -rf fis-conf-${framework}.js
        rm -rf output
    fi
done
<commit_msg>认证失败问题<commit_after>#!/usr/bin/env bash

ROOT=$(pwd)
FIS_CONFIG_TEMPLATE="$ROOT/fis-conf.js"
FRAMEWORKS=(fis-plus)

if [ "$1" = "" ];then
    output="output"
else
    output=$1
fi

domain=
if [ "$2" != "dev" ]; then
    domain="\/fis-plus"
fi

isDev=

if [ "$2" = "dev" ]; then
    isDev="dev"
else
    export PATH=$ROOT/node_modules/.bin:$PATH
    export NODE_PATH=$ROOT/node_modules
fi

gitpush_gh () {
    framework=$1
    git clone https://github.com/fex-team/${framework}.git
    cd "$framework"
    git checkout gh-pages
    rm -rf * #clear
    cp -rf ../output/* .
    git add *
    
    git commit -m 'update auto'
    
    git config --global user.email "<EMAIL>"
    git config --global user.name "xiangshouding"
    git config credential.helper "store --file=.git/credential"
    echo "https://${GH_TOKEN}:@github.com" > .git/credential
    
    git push origin gh-pages
    cd ..
    rm -rf "$framework"
}

for framework in $FRAMEWORKS; do
    echo $framework
    
    if [ "$isDev" = "" ]; then
        rm -rf $ROOT/doc
    fi
    
    cat $FIS_CONFIG_TEMPLATE | sed s/{%FRAMEWORK%}/${framework}/g > fis-conf-${framework}.js
    cat fis-conf-${framework}.js | sed s/{%DOMAIN%}/${domain}/g > fis-conf-${framework}_tmp.js
    mv fis-conf-${framework}_tmp.js fis-conf-${framework}.js
    
    if [ "$isDev" = "" ]; then
        git clone https://github.com/fex-team/${framework}.wiki.git $ROOT/doc
    fi
    
    fis release -cmDd $output -f fis-conf-${framework}.js
    if [ "$?" = "0" -a -d "./output" ]; then
        gitpush_gh "$framework"
        rm -rf fis-conf-${framework}.js
        rm -rf output
    fi
done

{'fraction_non_alphanumeric': 0.17310012062726177, 'fraction_numerical': 0.0036188178528347406, 'mean_word_length': 2.3881511746680286, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 11, 'https://': 6, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1703512', 'n_tokens_mistral': 1211, 'n_tokens_neox': 1201, 'n_words': 279}