7 Zip "access is denied" when I'm trying to edit archive

2

I'm trying to use Sublime Text 3 as a Java language tool and the internet says to edit the JavaC.sublime-build file in Java.sublime-package file. The problem is, when I'm trying to edit the archive using 7Zip, the program says "Access is denied" and "Can not update the archive in (Location of the file)". How do I solve this?

Enigma

Posted 2016-12-14T00:45:42.207

Reputation: 21

Answers

0

7-Zip might have problems updating files that use non-standard file-extensions.

I recommend using the PackageResourceViewer to extract files from installed packages. Once installed, follow these steps:

  1. Launch PackageResourceViewer: Open Resource from the command palette
  2. Browse for the Java package
  3. Select JavaC.sublime-build and press Enter

This will extract the file to the Packages folder and open it in the editor. You can now make changes and save the file. Changes will be immediately available. However, upgrading a package might overwrite your changes.

idleberg

Posted 2016-12-14T00:45:42.207

Reputation: 1 200

I edited the sublime-build file using PackageResourceViewer and I saved it, but somehow it does not work. When I open the sublime-build file using Sublime Text editor, there is the code I pasted in but when I open the file with 7 zip archive, there is no code I wanted (it is not saved). I changed the Building System and I hit Ctrl + B, it does not work. – Enigma – 2016-12-15T00:43:34.037

That's how it is supposed to work. See the chapter on Overrides in the Package Control documentation.

– idleberg – 2016-12-15T06:32:09.947

It seems to work, partially... Simple codes such as "Hello World" is printing but algorithm code (or code when you insert input, output comes out) does not work... Is my sublime-build code wrong then? { "cmd": ["JavaC", "$file_name","&&","java", "$file_base_name"], "file_regex": "^(...?):([0-9]):?([0-9]*)", "selector": "source.java", "shell": true } – Enigma – 2016-12-21T16:43:46.413

Does it work in your shell? You could try "shell_cmd": "JavaC $file_name && java $file_base_name" instead of using cmd – idleberg – 2016-12-21T19:57:56.173

That did not work... So there is an input-output codes I've written, and it works fine in jGRASP or Eclipse. But when I build this code on Sublime, the console comes out but nothing appears, not even "[Finished in seconds]" message. And when I use "shell_cmd" you gave, it says there's an error. – Enigma – 2016-12-23T18:06:07.990

I think Sublime Text is generally functioning well. I appreciate your help. Thank you again. – Enigma – 2016-12-26T21:45:03.930

0

Easy fix. Just run 7zip as administrator. From there on you will be granted access to edit JavaC.sublime-build however you pliz.

Did this and it solved the problem.

Phillip

Posted 2016-12-14T00:45:42.207

Reputation: 1