Hi Hugo,
You can set it in the workspace file or from vsCode:
- workspace file: (myproject.code-workspace)
{
       "folders": [
        {
            "path": "projectXXXX"
        }
    ],
    "settings": {
        "as3mxml.sdk.framework": 
"d:\\Develop_Royale\\Projects\\Royale-SDK\\royale-asjs",
        "as3mxml.sdk.editor": 
"D:\\Develop_Royale\\Projects\\Royale-SDK\\royale-asjs" 
<------------------------------ HERE ****************
    }
}

-  vsCode:
        - You can edit manually the file "settings.json" [1] (in Windows it is 
in C:\Users\hiedra\AppData\Roaming\Code\User\settings.json)
        - or from the IDE (File/Preferences/Settings) [2].
        
        [1] 
https://drive.google.com/file/d/1SE-29sJc08tXV5-GMBabPJJWGRfyj4u0/view?usp=sharing
        [2] 
https://drive.google.com/file/d/1nyC0JyHdD8441nEBks-mwIeElVs41tZQ/view?usp=sharing

Hiedra

-----Mensaje original-----
De: Hugo Ferreira <hferreira...@gmail.com> 
Enviado el: viernes, 1 de abril de 2022 21:44
Para: Apache Royale Development <dev@royale.apache.org>
Asunto: Re: New --watch compiler option

Where is the as3mxml.sdk.editor file ?
I didn't find it (macOS)


Josh Tynjala <joshtynj...@bowlerhat.dev> escreveu no dia sexta, 1/04/2022
à(s) 16:52:

> If you're going to add -watch to asconfig.json, you'll also need to 
> update the as3mxml.sdk.editor setting in VSCode to the path of your 
> new Royale SDK. vscode-as3mxml bundles Royale 0.9.8, so it doesn't 
> know anything about -watch, but as3mxml.sdk.editor lets it use a 
> custom SDK for code intelligence purposes.
>
> In a future update, vscode-as3mxml will have a built-in watch task so 
> that you won't need to modify asconfig.json. I have it working in a 
> branch right now.
>
> --
> Josh Tynjala
> Bowler Hat LLC <https://bowlerhat.dev>
>
>
> On Fri, Apr 1, 2022 at 3:48 AM Hugo Ferreira <hferreira...@gmail.com>
> wrote:
>
> > Does not work with me:
> >
> > asconfig.json:
> > {
> > "config": "royale",
> > "copySourcePathAssets": true,
> > "compilerOptions": {
> > "debug": false,
> > "targets": ["JSRoyale"],
> > "source-map": true,
> > "html-template": "src/resources/index-template.html",
> > "js-library-path": [
> > "${royalelib}/js/libs/MXRoyaleJS.swc"
> > ]
> > },
> > "additionalOptions": "-watch -remove-circulars 
> > -js-output-optimization=skipAsCoercions
> > -compiler.exclude-defaults-css-files=MXRoyale-0.9.10-js.swc:defaults
> > .css
> > -keep-as3-metadata+=Transient",
> > "files":
> > [
> > "src/App.mxml"
> > ]
> > }
> >
> > VS Code - Problems:
> > unknown configuration variable 'watch'.
> >
> >
> > Maria Jose Esteve <mjest...@iest.com> escreveu no dia sexta, 
> > 1/04/2022
> > à(s)
> > 11:08:
> >
> > > Forget you, I compiled the SDK last night but not this morning....
> > > Sorry for the noise. I'll compile and come back here with the results.
> > >
> > > Hiedra
> > >
> > > -----Mensaje original-----
> > > De: Maria Jose Esteve <mjest...@iest.com> Enviado el: viernes, 1 
> > > de abril de 2022 11:38
> > > Para: dev@royale.apache.org
> > > Asunto: RE: New --watch compiler option
> > >
> > > This is great, let's try it and debug it....
> > > - I added it in the "<additionalCompilerOptions>" section of the
> pom.xml
> > > of the application and I get the message:
> > >
> > > Error: configuration variable 'debug' must be true if 
> > > configuration variable 'watch' is true.
> > >
> > > - I activate debug, in the library and in the application and I 
> > > get the error " Got return code 1000":
> > >
> > > [INFO] --- royale-maven-plugin:0.9.10-SNAPSHOT:compile-app
> > > (default-compile-app) @ royalelogin --- [INFO] Executing MXMLC in 
> > > tool group Royale with args:
> > >
> >
> [-load-config=D:\Develop_Royale\Projects\WinPlusWebSuite\royaleapp\roy
> alelogin\target\compile-app-config.xml,
> > > -js-default-initializers=true, -source-map=true, --watch, 
> > > -js-dynamic-access-unknown-members=true,
> > >
> >
> -keep-as3-metadata+=Inject,Dispatcher,EventHandler,Event,PostConstruct
> -keep-as3-metadata+,PreDestroy,ViewAdded,ViewRemoved,Bindable,Transien
> -keep-as3-metadata+t,
> > > -keep-code-with-metadata=Inject, -show-binding-warnings=false, 
> > > -export-public-symbols=false, 
> > > -prevent-rename-protected-symbols=false,
> > > -prevent-rename-internal-symbols=false,
> > >
> >
> -js-output=D:\Develop_Royale\Projects\WinPlusWebSuite\royaleapp\royale
> login\target\javascript,
> > > -compiler.targets=JSRoyale,
> > >
> >
> D:\Develop_Royale\Projects\WinPlusWebSuite\royaleapp\royalelogin\src\m
> ain\royale\App.mxml]
> > > The project 'App' has been successfully compiled.
> > > [INFO]
> > >
> ----------------------------------------------------------------------
> --
> > > [INFO] Reactor Summary for W+Web! 1.0.0-SNAPSHOT:
> > > [INFO]
> > > [INFO] W+Web! ............................................. 
> > > SUCCESS [
> > > 0.098 s] [INFO] Royale Libs ........................................
> > > SUCCESS [  0.038 s] [INFO] Royale Libs Custom Theme 
> > > ........................... SUCCESS [  3.488 s] [INFO] Royale Lib
> > Component
> > > ECharts ....................... SUCCESS [  2.868 s] [INFO] Royale 
> > > Libs
> > Arq
> > > .................................... SUCCESS [  2.025 s] [INFO] 
> > > Royale
> > Libs
> > > Commons ................................ SUCCESS [  2.853 s] 
> > > Watching
> for
> > > file changes in target JSRoyale...
> > > [INFO] Royale Libs DTO .................................... 
> > > SUCCESS [
> > > 2.513 s] [INFO] Royale Libs Shell ..................................
> > > SUCCESS [  1.680 s] [INFO] Royale Libs Components 
> > > ............................. SUCCESS [ 10.894 s] [INFO] Royale 
> > > Libs Jscalendar ............................. SUCCESS [ 12.008 s] 
> > > [INFO]
> > Royale
> > > Lib Component InspireTree ................... SUCCESS [ 10.880 s]
> [INFO]
> > > Royale Lib Component Mobiscroll .................... SUCCESS [  
> > > 1.715
> s]
> > > [INFO] Royale Libs Security ............................... 
> > > SUCCESS [
> > > 1.984 s] [INFO] Royale Libs ConfigSystem ...........................
> > > SUCCESS [  1.949 s] [INFO] Royale Libs Personal 
> > > ............................... SUCCESS [  1.927 s] [INFO] Royale 
> > > Libs Horarios ............................... SUCCESS [  1.819 s] 
> > > [INFO]
> > Royale
> > > Libs Perfiles Horarios ...................... SUCCESS [  1.805 s]
> [INFO]
> > > Royale Libs Fichajes ............................... SUCCESS [  
> > > 1.720
> s]
> > > [INFO] Royale Libs Config ................................. 
> > > SUCCESS [
> > > 1.714 s] [INFO] Royale App And Modules .............................
> > > SUCCESS [  0.008 s] [INFO] Royale Application 
> > > ................................. FAILURE [ 18.214 s] [INFO]
> > >
> ----------------------------------------------------------------------
> --
> > > [INFO] BUILD FAILURE
> > > [INFO]
> > >
> ----------------------------------------------------------------------
> --
> > > [INFO] Total time:  01:23 min
> > > [INFO] Finished at: 2022-04-01T10:14:25+02:00 [INFO]
> > >
> ----------------------------------------------------------------------
> --
> > > [ERROR] Failed to execute goal
> > >
> >
> org.apache.royale.compiler:royale-maven-plugin:0.9.10-SNAPSHOT:compile
> -app
> > > (default-compile-app) on project royalelogin: There were errors 
> > > during
> > the
> > > build. Got return code 1000 -> [Help 1]
> > >
> > > If I launch the compilation with the detailed debugging, -e -X, to 
> > > file [1]. It shows:
> > >
> > > Exception in thread "Thread-3" Exception in thread "Thread-3"
> > > java.lang.NoClassDefFoundError:
> > > org/apache/royale/compiler/internal/watcher/WatchThread$1
> > >         at
> > >
> >
> org.apache.royale.compiler.internal.watcher.WatchThread.watchPath(Watc
> hThread.java:262)
> > >
> > >         at
> > >
> >
> org.apache.royale.compiler.internal.watcher.WatchThread.run(WatchThrea
> d.java:130)
> > > Caused by: java.lang.ClassNotFoundException:
> > > org.apache.royale.compiler.internal.watcher.WatchThread$1
> > >         at
> > >
> >
> org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(S
> elfFirstStrategy.java:50)
> > >         at
> > >
> >
> org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadCla
> ss(ClassRealm.java:271)
> > >
> > >         at
> > >
> >
> org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.
> java:247)
> > >         at
> > >
> >
> org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.
> java:239)
> > >         ... 2 more
> > >
> > > [1]
> > >
> >
> https://drive.google.com/file/d/18CC4_6XQ4YwJujTyBLwqpkg5q6oTfXvy/view
> ?usp=sharing
> > >
> > >
> > > Hiedra
> > >
> > > -----Mensaje original-----
> > > De: Josh Tynjala <joshtynj...@bowlerhat.dev> Enviado el: jueves, 
> > > 31 de marzo de 2022 23:49
> > > Para: dev@royale.apache.org; romanisi...@yahoo.com
> > > Asunto: Re: New --watch compiler option
> > >
> > > It should be in 0.9.10-SNAPSHOT (or will be when the next Maven 
> > > nightly build completes). To use this option with Maven, I assume 
> > > that you can
> > add
> > > --watch to the section of your pom.xml where you can specify 
> > > additional compiler options. I'm not familiar enough with the 
> > > Maven plugin to tell
> > you
> > > exactly where that is.
> > >
> > > --
> > > Josh Tynjala
> > > Bowler Hat LLC <https://bowlerhat.dev>
> > >
> > >
> > > On Thu, Mar 31, 2022 at 2:42 PM romanisi...@yahoo.com.INVALID 
> > > <romanisi...@yahoo.com.invalid> wrote:
> > >
> > > > This is a nice feature. Is it part of the new 0.9.9 release ? Or
> Which
> > > > snapshot version ?
> > > >
> > > > Also just to clarify usage. I use maven so will the usage be as 
> > > > follows mvn  clean watch install ?
> > > > How can I use it in a royale maven project ?
> > > >
> > > > Sent from Yahoo Mail on Android
> > > >
> > > >   On Thu, 31 Mar 2022 at 22:34, Josh Tynjala<
> joshtynj...@bowlerhat.dev
> > >
> > > > wrote:   Hi all,
> > > >
> > > > I just pushed a commit to royale-compiler that adds a new 
> > > > --watch compiler option. What this new option does is keep the 
> > > > compiler running after it's done, watching the source-path 
> > > > folders for any changes to .as and .mxml files. When changes are 
> > > > detected, it will automatically re-compile your project. Best of 
> > > > all, it's an incremental re-compile, so it will be significantly faster.
> > > >
> > > > For projects targeting JS, all you need to do is refresh your 
> > > > browser after the re-compile completes. You can even use a tool 
> > > > that does
> this
> > > > automatically, if you prefer.
> > > >
> > > > After a quick search on Google, I found the "reload" npm 
> > > > package, and I can confirm that it can automatically reload a 
> > > > Royale app after
> > > recompilation.
> > > > Here is the command that I used in a terminal at the root of my 
> > > > project
> > > > folder:
> > > >
> > > > npx reload -d bin/js-debug -b
> > > >
> > > > This starts a local HTTP server in the directory bin/js-debug, 
> > > > and it launches the app in a browser.
> > > >
> > > >
> > > >
> https://www.npmjs.com/package/reload#user-content-using-reload-as-a-co
> > > > mmand-line-application
> > > >
> > > > The new --watch compiler option works with SWF too. However, I'm 
> > > > not aware of any automatic reloading tools for this, so you'll 
> > > > just need to close and relaunch manually.
> > > >
> > > > Please give it a try, and let me know if you run into any 
> > > > issues. I'd like to see how well it works with some bigger projects!
> > > >
> > > > --
> > > > Josh Tynjala
> > > > Bowler Hat LLC <https://bowlerhat.dev>
> > > >
> > > >
> > >
> >
>

Reply via email to