Empty config in @electron-forge/publisher-nucleus@6.0.0-beta.22
See original GitHub issueIf you check config object assigned in https://github.com/electron-userland/electron-forge/blob/e55a9d5beb666a944ae730e6ed0a2ba6b5594c93/packages/publisher/nucleus/src/PublisherNucleus.ts#L35 it’s empty (regardless of how config declared as manifest block or a separate file) and therefore the fetch function https://github.com/electron-userland/electron-forge/blob/e55a9d5beb666a944ae730e6ed0a2ba6b5594c93/packages/publisher/nucleus/src/PublisherNucleus.ts#L57 receives empty config.host and throws an error (Absolute URL required).
As a dirty workaround I had to do the following, given I have the only publisher:
async publish({ makeResults, forgeConfig }: PublisherOptions) {
const config = forgeConfig.publishers[0].config
...
So it publishes correctly to Nucleus server
My env: Windows 10, Node.js 10.4.1
package.json
{
"name": "test",
"productName": "test",
"version": "1.0.0",
"description": "My Electron application description",
"main": "src/index.js",
"scripts": {
"start": "electron-forge start",
"package": "electron-forge package",
"make": "electron-forge make",
"publish": "electron-forge publish --target=@electron-forge/publisher-nucleus",
"lint": "echo \"No linting configured\""
},
"keywords": [],
"author": "dmitry",
"license": "MIT",
"config": {
"forge": "./forge.config.js"
},
"dependencies": {
"@electron-forge/publisher-nucleus": "^6.0.0-beta.22",
"electron-squirrel-startup": "^1.0.0"
},
"devDependencies": {
"@electron-forge/cli": "^6.0.0-beta.22",
"@electron-forge/maker-deb": "^6.0.0-beta.22",
"@electron-forge/maker-rpm": "^6.0.0-beta.22",
"@electron-forge/maker-squirrel": "^6.0.0-beta.22",
"@electron-forge/maker-zip": "^6.0.0-beta.22",
"electron": "2.0.5"
}
}
forge.config.js
module.exports = {
"packagerConfig": {},
"publishers": [
{
"name": "@electron-forge/publisher-nucleus",
"config": {
"host": "http://localhost:3030",
"appId": "2",
"channelId": "5542496b41ba12ab15a31862d78088f4",
"token": "TOKEN"
}
}
],
"makers": [
{
"name": "@electron-forge/maker-squirrel",
"config": {
"name": "test"
}
},
{
"name": "@electron-forge/maker-zip",
"platforms": [
"darwin"
]
},
{
"name": "@electron-forge/maker-deb",
"config": {}
},
{
"name": "@electron-forge/maker-rpm",
"config": {}
}
]
}
Issue Analytics
- State:
- Created 5 years ago
- Comments:9 (6 by maintainers)
Top Results From Across the Web
Empty Config files - Network Configuration Manager (NCM)
Sometimes one or more config files are empty and thereby different then the existing config. Does anyone have an idea of why I...
Read more >c# - What causes user.config to empty? And how do I restore ...
I have noticed on a few machines in which my application's user.config file is somehow becoming corrupted and is empty when opening.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@vintproykt per the docs,
host
includes the protocol.https://github.com/electron-userland/electron-forge/blob/a5bec3a872a2d4463c71f0f763afc2021f4a7f33/packages/publisher/nucleus/src/PublisherNucleus.ts#L57 ~No port specified.~ Nevermind.