I've copied my programs over to a new mac, installed VS and Java and they are not working. I think there might be permission issues. Thoughts?

Hello,

I bought a new Mac and copied my Garmin apps over.  I installed the SDK and VS Code.  The app, unmodified says it cannot find a file which is there (it was a relative position, so no complex directory change). When I then moved the image to the same directory and fixed the bitmap line, I had to use sudo to save it.  It still did not work.

I gave VS all file permissions in System Settings, Privacy and Security, and granting it Full Disk Access.  I also did Instal 'code' command in path inside VS Code.  The only other thing I can think of is that it is having problems with FileVault being on.

Thoughts?

Thanks,

Jeff

  • We didn't see your exact error message but is the root application folder (not any of its parent folders) selected as a workspace in VS Code?

  • Hello,

    Newb question, How do I see/set the root application folder as a workspace?  I ran...

    From the CMD+Shift+P menu.  I did a full restart afterwards.

    This is the save error.

    This is the image error.

    Jeff

  • To be 120% sure that the app root folder = workspace folder you can create a file named "<YourAppName>.code-workspace" inside the root app folder and fill it with such content:

    {
        "folders": [
            {
                "path": "."
            }
        ]
    }

    And then just do File -> Open Workspace from File... in VS Code and select this file.

  • Can you share the path to your project (redacted if necessary)?

    What happens if you just create a new project as a subfolder of your Documents folder? Or if you move the project folder to your Documents folder?

    Are you able to use Terminal or Finder to create files/folders in your current project folder, without being asked for additional authorization?

  • One step forward...

    It appears that I needed to go into my folders ("Garmin Projects" in my case), select get info, change read and write privileges to everyone (versus just me) and tell that to filter to all sub folders. FlowState got me moving in that direction.  Now...if that was the cure all, I don't know.  I'm getting new errors with my function creations...

    function onLayout(dc as Dc) as Void {
    and 
    function getInitialView() as Array<Views or InputDelegates>? {
    Apparently, there's been some updates since I've written my programs.
    Thank you for helping me.
    Jeff
  • Turns out my old apps were being executed in the old SDKs.  Since I did the new install, I used the new SDK.  I had to add "as Text" to the end of all my View statements 

                View.findDrawableById("labelHere") as Text;
    and get rid of the "using" "as" in my imports
                import Toybox.WatchUi; instead of using Toybox.WatchUi as Ui;
    Gonna call this closed.
    Thanks again.