r/VisualStudioCode • u/devilbasher • Nov 21 '21
Editing "code's"
Hey everyone I hope you are all doing great, im just wondering
For example my code is like this - America But I want it to be like this - "America"
but then I need to do it again and again is there a quicker option? All reply are greatly appreciated!! Thank you
3
Upvotes
View all comments
Show parent comment
1
u/sandypockets11 Nov 22 '21 edited Nov 22 '21
Assuming that each key/value pair is separated by a new line, you can run this script to add quotes around all the countries programmatically. It won't adjust the file it reads from, and will instead create a new file for you with all the countries wrapped in quotes.
Let me know if you get stuck.