I tried changing javac.sublime-build-package and i got notification access denied

49 views Asked by At

I was trying to change javac file text but it was not changing so I tried to delete and replace it with the below text copy when I tried deleting javac in Sublime java package it pops up notification "access denied". How can I replace it?

{
"cmd": ["javac", "$file_name","&&","java", "$file_base_name"],
"file_regex": "^(...?):([0-9]):?([0-9]*)",
"selector": "source.java",
"shell": true
}
1

There are 1 answers

2
idleberg On

When you want to adjust an existing package, you shouldn't try to overwrite the original files. Think about it, once the package updates to a newer version, your changes will be gone.

Instead, Sublime Text offers different ways to customize packages – as mentioned in the Package Control documentation:

If a package for Sublime Text 3 is installed as a packed package, it should be possible to directly override individual non-python files. To do this, create a Packages/{Package Name}/ folder and save customized versions of the files with the same name they are in the .sublime-package file.

As mentioned by MattDMo, you can also create by additional build systems by saving the to Packages/User. You will then be able to select them from the build menu.

On a side note, make sure that your .sublime-build file is valid JSON – the enter code here part in your example makes it invalid!