File tree Expand file tree Collapse file tree 2 files changed +28
-12
lines changed
Expand file tree Collapse file tree 2 files changed +28
-12
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ package rapid
99import "strings"
1010
1111// sourced from https://data.iana.org/TLD/tlds-alpha-by-domain.txt
12- // Version 2020103100 , Last Updated Sat Oct 31 07:07:01 2020 UTC
12+ // Version 2021090100 , Last Updated Thu Sep 2 02:57:25 UTC 2021
1313const tldsByAlpha = `
1414AAA
1515AARP
@@ -224,7 +224,6 @@ CAREERS
224224CARS
225225CASA
226226CASE
227- CASEIH
228227CASH
229228CASINO
230229CAT
236235CBS
237236CC
238237CD
239- CEB
240238CENTER
241239CEO
242240CERN
@@ -474,7 +472,6 @@ FRONTDOOR
474472FRONTIER
475473FTR
476474FUJITSU
477- FUJIXEROX
478475FUN
479476FUND
480477FURNITURE
@@ -640,11 +637,9 @@ ISTANBUL
640637IT
641638ITAU
642639ITV
643- IVECO
644640JAGUAR
645641JAVA
646642JCB
647- JCP
648643JE
649644JEEP
650645JETZT
760755LTDA
761756LU
762757LUNDBECK
763- LUPIN
764758LUXE
765759LUXURY
766760LV
849843NAB
850844NAGOYA
851845NAME
852- NATIONWIDE
853846NATURA
854847NAVY
855848NBA
@@ -862,7 +855,6 @@ NETFLIX
862855NETWORK
863856NEUSTAR
864857NEW
865- NEWHOLLAND
866858NEWS
867859NEXT
868860NEXTDIRECT
910902ONG
911903ONL
912904ONLINE
913- ONYOURSIDE
914905OOO
915906OPEN
916907ORACLE
@@ -1110,7 +1101,6 @@ SHOPPING
11101101SHOUJI
11111102SHOW
11121103SHOWTIME
1113- SHRIRAM
11141104SI
11151105SILK
11161106SINA
@@ -1144,7 +1134,6 @@ SPA
11441134SPACE
11451135SPORT
11461136SPOT
1147- SPREADBETTING
11481137SR
11491138SRL
11501139SS
@@ -1358,6 +1347,7 @@ XN--42C2D9A
13581347XN--45BR5CYL
13591348XN--45BRJ9C
13601349XN--45Q11C
1350+ XN--4DBRK0CE
13611351XN--4GBRIM
13621352XN--54B7FTA0CC
13631353XN--55QW42G
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
2+
3+ set -eu
4+
5+ TLD_URL=https://data.iana.org/TLD/tlds-alpha-by-domain.txt
6+ TLD=" $( curl -fsSL https://data.iana.org/TLD/tlds-alpha-by-domain.txt | grep -v ' ^#' ) "
7+
8+ cat > tld.go << EOF
9+ // Copyright 2020 Walter Scheper <walter.scheper@gmail.com>
10+ //
11+ // This Source Code Form is subject to the terms of the Mozilla Public
12+ // License, v. 2.0. If a copy of the MPL was not distributed with this
13+ // file, You can obtain one at https://mozilla.org/MPL/2.0/.
14+
15+ package rapid
16+
17+ import "strings"
18+
19+ // sourced from https://data.iana.org/TLD/tlds-alpha-by-domain.txt
20+ // Version $( date +%Y%m%d00) , Last Updated $( date --utc)
21+ const tldsByAlpha = \`
22+ ${TLD}
23+ \`
24+
25+ var tlds = strings.Split(strings.TrimSpace(tldsByAlpha), "\n")
26+ EOF
You can’t perform that action at this time.
0 commit comments