2

I am using wgrep but somehow for those read-only files (under version control), it always reports not to apply changes. Even the var of wgrep-change-readonly-file is set to t. Any idea how to fix it?

Dan
  • 32,980
  • 7
  • 102
  • 169
macs
  • 21
  • 2

1 Answers1

3

The Github README says that the variable actually means read-only buffers, not read-only files:

To apply all changes wheather or not buffer is read-only.

(setq wgrep-change-readonly-file t)

You cannot modify read-only files by definition. You must adjust the files' attributes in order to do so. This varies depending on your operating system and file system.

nanny
  • 5,756
  • 1
  • 20
  • 38
  • I tried to open them in advanced, but it still does not work and can not change the read-only property of these buffers. Are these steps correct? – macs Dec 03 '15 at 04:43
  • @macs I just tried it out, and it works fine. – nanny Dec 03 '15 at 14:09