参照相关文档,在package.json中配置electron-builder的基础打包设置:
"build": { "productName": "Fishing Funds", "appId": "com.electron.1zilc.fishing-funds", "copyright": "Copyright © 2021 1zilc", "files": [ "dist/", "node_modules/", "index.html", "main.prod.js", "main.prod.js.map", "package.json" ], "afterSign": ".erb/scripts/Notarize.js", "mac": { "target": [ "dmg" ], "type": "distribution", "hardenedRuntime": true, "entitlements": "assets/entitlements.mac.plist", "entitlementsInherit": "assets/entitlements.mac.plist", "gatekeeperAssess": false }, "dmg": { "contents": [ { "x": 130, "y": 220 }, { "x": 410, "y": 220, "type": "link", "path": "/Applications" } ] }, "win": { "target": [ "nsis" ] }, "linux": { "target": [ "AppImage" ], "category": "Development" }, "directories": { "app": "src", "buildResources": "assets", "output": "release" }, "extraResources": [ "./assets/**" ] },
在该配置的基础上添加 publish key,如下:
"publish": { "provider": "github", "owner": "1zilc", "repo": "fishing-funds" }
以我自己的 Fishing Funds 为例
添加github token,网址如下: https://github.com/settings/tokens/new

勾选repo仓库相关权限
生成token后,临时添加环境变量中
export GH_TOKEN="<YOUR_TOKEN_HERE>"
在package.json中编写scripts,根据实际情况做调整
"scripts": { "build": "concurrently \"yarn build:main\" \"yarn build:renderer\"", "build:main": "cross-env NODE_ENV=production webpack --config ./.erb/configs/webpack.config.main.prod.babel.js", "build:renderer": "cross-env NODE_ENV=production webpack --config ./.erb/configs/webpack.config.renderer.prod.babel.js", "package": "rm -rf src/dist && yarn build && electron-builder build --publish never", "package-mac": "rm -rf src/dist && yarn build && electron-builder build --mac -p always", "package-linux": "rm -rf src/dist && yarn build && electron-builder build --linux", "package-win": "rm -rf src/dist && yarn build && electron-builder build --win --x64", "package-all": "rm -rf src/dist && yarn build && electron-builder build -mwl", "release-all": "rm -rf src/dist && yarn build && electron-builder build -mwl --publish always" },
# 添加发布参数即release-all中所写 electron-builder build --publish always
执行
yarn release-all

构建完成后会自动通过刚才设置的token去调github的发布接口,此时仓库中会自动生成一个草稿状态的release,在填写相关日志后即可进行版本发布
electron-builder 自动发布 github release 到此完成! 🙂
wonderful points altogether, you just received a brand
new reader. What may you suggest about your submit that you simply made a few days ago?
Any certain?
I’m now not sure the place you’re getting your information, but great topic.
I needs to spend some time studying more or understanding more.
Thank you for great information I was on the lookout for this
info for my mission.
Excellent post. Keep posting such kind of info on your site.
Im really impressed by your blog.
Hello there, You’ve performed a fantastic job. I’ll definitely digg it and individually suggest to my friends.
I am sure they will be benefited from this site.
Please let me know if you’re looking for a article
writer for your site. You have some really great articles
and I think I would be a good asset. If you ever want to take some of the load off,
I’d love to write some content for your blog in exchange for a link
back to mine. Please shoot me an e-mail if interested.
Regards!
Do you have a spam problem on this blog; I also am a blogger,
and I was curious about your situation; many of us have created some nice procedures and we are looking
to swap solutions with other folks, be sure to shoot me an email if interested.
Hey there! I know this is kinda off topic nevertheless I’d figured
I’d ask. Would you be interested in trading links
or maybe guest authoring a blog post or vice-versa?
My website addresses a lot of the same topics
as yours and I believe we could greatly benefit from each other.
If you happen to be interested feel free to shoot me an e-mail.
I look forward to hearing from you! Awesome blog by the way!
Wow, this piece of writing is nice, my sister is analyzing these kinds
of things, so I am going to let know her.
Wonderful goods from you, man. I’ve understand your stuff previous to and you are just too great.
I actually like what you have acquired here, really like what you’re stating and the way in which
you say it. You make it enjoyable and you still take
care of to keep it sensible. I cant wait to read much more from you.
This is actually a great web site.
whoah this weblog is magnificent i love reading your
posts. Stay up the great work! You understand, a lot of individuals are
searching around for this info, you could aid them greatly.
Hi! This is my first visit to your blog! We are
a team of volunteers and starting a new initiative in a community in the same niche.
Your blog provided us useful information to work on. You have done
a wonderful job!
Hi, i feel that i noticed you visited my site so i got here to go back
the desire?.I am attempting to to find issues to improve
my site!I suppose its good enough to use a few
of your ideas!!
Hi! This is my first visit to your blog! We are a collection of volunteers and
starting a new project in a community in the same niche.
Your blog provided us useful information to work on. You have done a
extraordinary job!
I’m really impressed with your writing skills and
also with the layout on your weblog. Is this a paid theme or did you
modify it yourself? Either way keep up the nice quality writing, it is rare
to see a nice blog like this one today.
The article is really excellent. Every time I read it, I get information again.
The best article I’ve read in a long time…. Thank Youuu.
Thank you for some other magnificent article. The place else
may just anybody get that type of info in such a perfect manner of writing?
I’ve a presentation next week, and I am on the look for such info.
I think this is among the most important info for me.
And i am glad reading your article. But want to remark on some
general things, The web site style is wonderful, the articles is really excellent
: D. Good job, cheers
With havin so much content and articles do you ever
run into any issues of plagorism or copyright infringement?
My website has a lot of exclusive content I’ve either
written myself or outsourced but it appears a lot of
it is popping it up all over the internet without my authorization. Do you know any solutions
to help protect against content from being ripped
off? I’d really appreciate it.
Wonderful, what a blog it is! This website presents helpful facts to us, keep it up.
Generally I don’t learn post on blogs, but I would like to say that this write-up very pressured me
to check out and do it! Your writing style has been surprised me.
Thank you, quite nice article.
Do you have a spam issue on this site; I also am a blogger, and I was wondering
your situation; we have created some nice procedures and we are
looking to trade strategies with others, be sure
to shoot me an email if interested.
This is the perfect website for anybody who wants to understand this topic.
You know a whole lot its almost hard to argue with
you (not that I personally would want to…HaHa).
You certainly put a brand new spin on a subject that’s been written about for many years.
Wonderful stuff, just great!
For latest information you have to pay a visit world-wide-web and on web I found this site
as a most excellent website for most recent updates.
When some one searches for his required thing, so he/she
desires to be available that in detail, so that thing is maintained over here.
Quality articles or reviews is the main to be a focus for the users to pay a visit
the site, that’s what this web page is providing.
I am truly glad to glance at this webpage posts which contains plenty of
useful data, thanks for providing these statistics.
I really love your blog.. Great colors & theme. Did you make
this site yourself? Please reply back as I’m hoping to create my very own website and would love to find out
where you got this from or just what the theme is named.
Appreciate it!
Usually I don’t read post on blogs, but I wish to say that this write-up very compelled
me to take a look at and do it! Your writing style has
been surprised me. Thanks, very great article.
I’m really enjoying the design and layout of your blog. It’s a very easy on the eyes which makes it much more pleasant for me to come here and
visit more often. Did you hire out a developer to create
your theme? Great work!
I was wondering if you ever considered changing the
structure of your website? Its very well written; I love what youve got to say.
But maybe you could a little more in the way of content so
people could connect with it better. Youve got an awful
lot of text for only having one or 2 images. Maybe you could space it out better?
Definitely consider that which you stated. Your favorite justification seemed to
be at the net the easiest factor to take note of.
I say to you, I certainly get irked while folks consider concerns that they plainly don’t understand about.
You controlled to hit the nail upon the highest and outlined out the
whole thing without having side-effects , other people can take
a signal. Will probably be back to get more. Thanks
Hey There. I found your weblog the usage of msn. That is a very well written article.
I’ll be sure to bookmark it and return to learn more
of your useful information. Thank you for the post. I’ll definitely comeback.
Hi, I do believe this is a great web site.
I stumbledupon it 😉 I’m going to come back yet again since
i have bookmarked it. Money and freedom is the greatest way to change,
may you be rich and continue to guide others.
Heya just wanted to give you a quick heads up and let you know a few
of the pictures aren’t loading properly. I’m not sure why
but I think its a linking issue. I’ve tried it in two different web browsers and both show the
same outcome.
Thanks for sharing your info. I really appreciate your efforts and I will be waiting for your further
post thank you once again.
Hi there colleagues, pleasant paragraph and nice arguments commented at this place, I am genuinely
enjoying by these.
Hi would you mind letting me know which webhost you’re working with?
I’ve loaded your blog in 3 different web browsers and I must say this
blog loads a lot quicker then most. Can you suggest a good
internet hosting provider at a honest price?
Cheers, I appreciate it!
If some one wants to be updated with most recent technologies after that he must be visit this web page
and be up to date daily.
Girls getting choked is a “kink”. Rough sex is a “kink”.
If you cant get off unless youre watching someone take your money or guzzle chocolate syrup or some
shit you arent “kinky” your a “fetishist”.
Outstanding post however I was wanting to know if you could write a litte more on this subject?
I’d be very thankful if you could elaborate a little bit further.
Thanks!
What’s up friends, its wonderful piece of writing about educationand entirely explained, keep
it up all the time.
Paragraph writing is also a excitement, if you know afterward you can write otherwise it is complex to write.
I’m really inspired together with your writing
abilities and also with the layout in your weblog. Is this
a paid subject matter or did you customize it your self?
Either way keep up the nice quality writing, it is uncommon to look a great
weblog like this one nowadays..
Hello, this weekend is fastidious for me, since this occasion i am reading this great educational paragraph here at my house.
At this time I am going away to do my breakfast, later than having my breakfast coming
again to read more news.
But as writer Peggy Orenstein discovered while
carrying out research on her new manual, “Boys & Sex: Young Men on Hookups, Love, Porn, Consent, as well as Navigating the New Masculinity” (Harper),
out right now, the fact can be actually really various.
Before Porn, sex was actually plain. You a lot better
be prepared to view such premium HD sexual activity video clips
as they include thoughts going scenes, great information and the greatest top
quality functions online. Get well-balanced. Moderate physical exercise, extending, or even yoga exercise is actually extremely favorable while naked,
specifically before an uncut looking glass, as one may see
which muscle mass and ligaments enter into action. These women are actually therefore
uninhibited that a person can rarely believe. Assuming this holds true, the very best task is to join our web-based dating internet site when you can. My
BF and also I have been actually dating for 4 months now.
The branch of the internet sites in to the groups stated above,
make the consumers look easy and also quickly, so they’ll have a terrific consumer encounter.
There is actually still much more things I haven’t fully tested, like Dex (Desktop
Experience).
Your style is unique in comparison to other people I have read stuff from.
Many thanks for posting when you have the opportunity, Guess I’ll just
book mark this web site.
Heya i’m for the first time here. I came across this board
and I find It really useful & it helped me out a lot.
I hope to give something back and aid others like you helped me.
Hello there! I know this is kind of off topic but I was
wondering which blog platform are you using for this website?
I’m getting tired of WordPress because I’ve had problems with hackers and
I’m looking at options for another platform.
I would be awesome if you could point me in the direction of a good platform.
Hello There. I discovered your weblog the usage of msn. That is an extremely neatly written article.
I’ll be sure to bookmark it and come back to learn more of your helpful information.
Thanks for the post. I will definitely return.
Sweet blog! I found it while surfing around on Yahoo
News. Do you have any suggestions on how to get listed
in Yahoo News? I’ve been trying for a while but I never seem to get
there! Appreciate it