p2-inc / phasetwo-admin-portal

Other
18 stars 14 forks source link

mvn clean build error #141

Closed bensaadmohamed closed 3 months ago

bensaadmohamed commented 3 months ago

hello when i build the extension with mvn clean packege to generate a jar file it give an error ./login/index.html doesnt exist

xgp commented 3 months ago

Sorry, there not enough here for me to reproduce. When does it give that error? How are you installing and running it?

bensaadmohamed commented 3 months ago

Ok, I'll try to clarify things a little I think the problem is with the packagege json variable PUBLIC_URL when building on windows the %PUBLIC_URL% variable in Index.html file has no value . so the CSS and JS has not been loaded correctly I replaced "PUBLIC_URL= '${authUrl}/realms/${realmName}/portal' react-scripts" in package.json with "Set PUBLIC_URL= ${authUrl}/realms/${realmName}/portal&&react-scripts build", After building this time the variable %PUBLIC_URL% got replaced by but The variable ${realmName} has no value and has not been replaced

xgp commented 3 months ago

Sorry but I have no ability to debug on Windows. If you want to figure out the problem and submit a patch that will work on all platforms, happy to look at it. In the meantime, I recommend you build on a unix variant.