Skip to content

build: compile 1.2.21 #195

build: compile 1.2.21

build: compile 1.2.21 #195

Workflow file for this run

name: Upload To WeixinMiniProgram
on:
push:
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
jobs:
upload:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- shell: bash
env:
PRIVATE_KEY: ${{ secrets.MP_PRIVATE_KEY }}
APPID: ${{ secrets.MP_APPID }}
run: |
if [[ -z $PRIVATE_KEY ]]; then
echo "##########"
echo ""
echo "Please set 'MP_PRIVATE_KEY' key in actions secrets"
echo ""
echo "##########"
exit 1
else
echo "$PRIVATE_KEY" > private.key
echo '{
"weixin": {
"appid": "'$APPID'",
"privateKeyPath": "private.key",
"projectPath": "dist/build/mp-weixin",
"setting": {
"minifyJS": true,
"minifyWXML": true,
"minifyWXSS": true,
"minify": true
}
},
"version": "",
"desc": ""
}' > .minicirc
fi
- name: Install pnpm
run: corepack enable
- uses: actions/setup-node@v3
with:
node-version: '18'
cache: 'pnpm'
- name: upload
run: |
npm i uni-mini-ci -g
pnpm install
pnpm upload:mp-weixin