[jbosstools-issues] [JBoss JIRA] (JBDS-3682) Online installer reports missing package.js file

Denis Golovin (JIRA) issues at jboss.org
Thu Mar 17 20:58:00 EDT 2016


     [ https://issues.jboss.org/browse/JBDS-3682?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Denis Golovin updated JBDS-3682:
--------------------------------
    Description: 
Installer now files to load path.resolve('./package.json') file and fails, because file not found. In this case it tries to resolve from folder where installer started, which is a temp folder where electron installer unpacked all the files after start. package.json real location is in app subfolder which can be referenced by __pathname variable plus one level up. 

Right way to reference package json would be different for development and runtime (see attached PR);

  was:
Installer now files to load path.resolve('./package.json') file and fails, because file not found. In this case it tries to resolve from folder where installer started, which is a temp folder where electron installer unpacked all the files after start. package.json real location is in app subfolder which can be referenced by __pathname variable plus one level up. 

Right way to reference package json would be:
{code}var pjson = require(path.join(__dirname,'../package.json'));{code}



> Online installer reports missing package.js file
> ------------------------------------------------
>
>                 Key: JBDS-3682
>                 URL: https://issues.jboss.org/browse/JBDS-3682
>             Project: Developer Studio (JBoss Developer Studio)
>          Issue Type: Bug
>          Components: installer
>    Affects Versions: 9.1.0.CR1
>            Reporter: Denis Golovin
>            Assignee: Denis Golovin
>              Labels: havoc
>
> Installer now files to load path.resolve('./package.json') file and fails, because file not found. In this case it tries to resolve from folder where installer started, which is a temp folder where electron installer unpacked all the files after start. package.json real location is in app subfolder which can be referenced by __pathname variable plus one level up. 
> Right way to reference package json would be different for development and runtime (see attached PR);



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)


More information about the jbosstools-issues mailing list