Saya menemukan diri saya sendiri perlu melakukan ini, dan membuat Regular Expression yang memungkinkan saya untuk mengubah semua bidang Status dari “todo” menjadi “deleted” berdasarkan per buku. Saya perhatikan bahwa format/urutan bidang di file XML selalu konsisten:

image1284×121 7.28 KB
Jadi saya mampu membuat ekspresi yang menemukan VerseRef di buku tertentu, mengabaikan sisa baris tersebut, lalu melewati sejumlah baris yang dimulai dengan spasi dan kemudian <S atau <C, lalu mencari baris yang dimulai dengan spasi dan kemudian <Status>todo. Ekspresi ini akan mengubah “todo” tersebut menjadi “deleted”. Berikut adalah ekspresinya:
Find: (VerseRef="\dJN .+\r\n(\s+<[SC].+\r\n)*?\s+<Status>)todo
Replace: \1deleted
Jadi di editor teks yang bisa bekerja dengan Regular Expressions (Notepad++ jika Anda tidak punya favorit), gunakan string find dan replace tersebut untuk menemukan semua catatan yang belum diselesaikan di 1JN, 2JN, 3JN, dan mengubahnya menjadi selesai.
\dJN dalam ekspresi find menggunakan RegEx lebih lanjut untuk menemukan catatan di semua buku yang dimulai dengan angka dan kemudian JN. Anda bisa mengganti string tersebut dengan kode buku lainnya untuk menemukan catatan di buku itu, misalnya MAT, ISA, atau hal-hal seperti \dCO untuk 1CO dan 2CO.
Harapan ini membantu seseorang di luar sana (dan mungkin membantu saya jika saya harus melakukannya lagi…
)
I found myself needing to do this, and created a Regular Expression that allows me to change all of the Status fields from “todo” to “deleted” on a book by book basis. I noticed that the format/order of the fields in the XML file was always consistent:

image1284×121 7.28 KB
So I was able to create an expression that finds a VerseRef in a particular book, ignores the rest of that line, then skips over any number of lines that begin with spaces and then a <S or <C, then looks for a line that starts with spaces and then <Status>todo. It will change that “todo” to “deleted”. Here is the expression:
Find: (VerseRef="\dJN .+\r\n(\s+<[SC].+\r\n)*?\s+<Status>)todo
Replace: \1deleted
So in a text editor that can work with Regular Expressions (Notepad++ if you don’t have a favorite), use those find and replace strings to find all of the notes that are not resolved in 1JN, 2JN, 3JN, and change them to resolved.
The \dJN in the find expression uses a further RegEx to find notes in all books that start with a digit and then JN. You can replace that string with another book code to find the notes in that book, e.g. MAT, ISA, or things like \dCO for 1CO and 2CO.
Hope that helps someone out there (and might help me if I have to do it again…
)
Diterjemahkan secara otomatis dari English