I have approx 6k urls to put into a .json
list in my iOS app
[{
"trigger": {
"url-filter": "somepage1.com",
"load-type" : ["third-party"]
},
"action": {
"type": "doSoemthing"
}
}, {
"trigger": {
"url-filter": "somepage2.com",
"load-type" : ["third-party"]
},
"action": {
"type": "doSoemthing"
}
}, {
"trigger": {
"url-filter": "anotherpage.net",
"load-type" : ["third-party"]
},
"action": {
"type": "doSoemthing"
}
}, {
"trigger": {
"url-filter": "yetanotherone.net", <---replace with another 6k
"load-type" : ["third-party"]
},
"action": {
"type": "doSoemthing"
}]
...etc
Im after an efficient way to automate this (efficient for entering data manually rather than cpu processing efficiency). Not having really done anything but very basic json before, i'm wondering if there is a way I can make an array
in my .json.class
and interpole all the urls?
Or
Perhaps using textwrangler. I realise this wouldn't work in Text Wrangler "as is", this is just to illustrate what I would like to achieve
The individual urls are in raw text format list