Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions Scripts/DoubleQuotesToSingles.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
{
"api":1,
"name":"Double Quotes to Singles",
"description":"Converts all double quotes to single quotes",
"author":"Joshfindit",
"icon":"quote",
"tags":"convert,quote,quotes,json"
}
**/

function main(state) {
try {
state.text = state.fullText.replace(/"/g, "'")
}
catch(error) {
state.postError("Something strange happened while trying to replace quotes")
}
}
19 changes: 19 additions & 0 deletions Scripts/SingleQuotesToDoubles.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
{
"api":1,
"name":"Single Quotes to Doubles",
"description":"Converts all single quotes to double quotes",
"author":"Joshfindit",
"icon":"quote",
"tags":"convert,quote,quotes,json"
}
**/

function main(state) {
try {
state.text = state.fullText.replace(/'/g, '"')
}
catch(error) {
state.postError("Something strange happened while trying to replace quotes")
}
}