electron-publisher-cos
v1.0.4
Published
Electron builder publish plugin for Tencent Cloud COS
Downloads
15
Maintainers
Readme
electron-publisher-cos
Electron builder publish plugin for Tencent Cloud COS
腾讯云 COS electron-builder
发布插件
Install
npm install --save-dev electron-publisher-cos
or
yarn add electron-publisher-cos -D
Usage
- Update the
electron-builder
configuration options for thepublish
provider.
// electron-builder.config.js
{
"publish": [
{
"provider": "generic",
"publishAutoUpdate": true,
// or your cdn url
"url": "https:///${name}/${os}/${arch}/"
},
{
"provider": "custom",
"providerName": "cos",
"publishAutoUpdate": true,
"bucket": "your-cos-bucket",
"region": "your-cos-region",
"path": "your-cos-path",
/**
* If you are using the environment variables COS_SECRET_ID and COS_SECRET_KEY, you can omit the settings here.
*/
"secretId": process.env.secretId,
"secretKey": process.env.secretKey,
}
]
}
- Add
electron-publisher-custom.js
onbuild
folder.
// build/electron-publisher-custom.js
const COSPublisher = require('electron-publisher-cos');
module.exports = COSPublisher;