airline-codes 1.1.5 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/.keepalive +1 -0
- package/.github/workflows/publish.yml +5 -2
- package/.github/workflows/update-data.yml +19 -2
- package/AGENTS.md +1 -5
- package/airlines.dat +8 -8
- package/airlines.json +9 -9
- package/normalize.js +9 -0
- package/package.json +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
2026-09-08T01:07:56Z
|
|
@@ -3,6 +3,9 @@ name: Publish to npm
|
|
|
3
3
|
on:
|
|
4
4
|
push:
|
|
5
5
|
branches: [master]
|
|
6
|
+
paths-ignore:
|
|
7
|
+
- '.github/**'
|
|
8
|
+
- '*.md'
|
|
6
9
|
workflow_dispatch:
|
|
7
10
|
|
|
8
11
|
jobs:
|
|
@@ -14,9 +17,9 @@ jobs:
|
|
|
14
17
|
- uses: actions/checkout@v4
|
|
15
18
|
- uses: actions/setup-node@v4
|
|
16
19
|
with:
|
|
17
|
-
node-version: '
|
|
20
|
+
node-version: '22'
|
|
18
21
|
registry-url: 'https://registry.npmjs.org'
|
|
19
|
-
- run: npm install -g npm@
|
|
22
|
+
- run: npm install -g npm@11
|
|
20
23
|
- run: npm install
|
|
21
24
|
- name: Publish if version not already published
|
|
22
25
|
run: |
|
|
@@ -14,7 +14,7 @@ jobs:
|
|
|
14
14
|
- uses: actions/checkout@v4
|
|
15
15
|
- uses: actions/setup-node@v4
|
|
16
16
|
with:
|
|
17
|
-
node-version: '
|
|
17
|
+
node-version: '22'
|
|
18
18
|
registry-url: 'https://registry.npmjs.org'
|
|
19
19
|
- run: npm ci
|
|
20
20
|
- name: Fetch latest airlines.dat from OpenFlights
|
|
@@ -28,10 +28,27 @@ jobs:
|
|
|
28
28
|
git config user.name "github-actions[bot]"
|
|
29
29
|
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
30
30
|
if git diff --quiet airlines.dat airlines.json; then
|
|
31
|
-
echo "No data changes
|
|
31
|
+
echo "No data changes."
|
|
32
|
+
# GitHub automatically disables scheduled workflows if there are no repository commits for 60 days.
|
|
33
|
+
# If no commits have been made in the last 40 days, create a keepalive commit to reset the timer.
|
|
34
|
+
LAST_COMMIT_TS=$(git log -1 --format=%ct)
|
|
35
|
+
NOW_TS=$(date +%s)
|
|
36
|
+
DAYS_SINCE=$(( (NOW_TS - LAST_COMMIT_TS) / 86400 ))
|
|
37
|
+
echo "Days since last commit: $DAYS_SINCE"
|
|
38
|
+
if [ "$DAYS_SINCE" -ge 40 ]; then
|
|
39
|
+
echo "Repository inactive for $DAYS_SINCE days (>= 40 days); creating keepalive commit to prevent workflow disable."
|
|
40
|
+
date -u +"%Y-%m-%dT%H:%M:%SZ" > .github/.keepalive
|
|
41
|
+
git add .github/.keepalive
|
|
42
|
+
if ! git diff --staged --quiet; then
|
|
43
|
+
git commit -m "chore(keepalive): touch .github/.keepalive [skip ci]"
|
|
44
|
+
git pull --rebase origin master
|
|
45
|
+
git push origin master
|
|
46
|
+
fi
|
|
47
|
+
fi
|
|
32
48
|
else
|
|
33
49
|
npm version patch --no-git-tag-version
|
|
34
50
|
git add airlines.dat airlines.json package.json package-lock.json
|
|
35
51
|
git commit -m "chore: update airline data from OpenFlights"
|
|
52
|
+
git pull --rebase origin master
|
|
36
53
|
git push origin master
|
|
37
54
|
fi
|
package/AGENTS.md
CHANGED
|
@@ -23,8 +23,4 @@
|
|
|
23
23
|
|
|
24
24
|
## Verifying issues
|
|
25
25
|
|
|
26
|
-
Before implementing a reported data correction, verify the claim against at least one authoritative source (e.g. [airhex.com](https://airhex.com), [IATA code search](https://www.iata.org/en/publications/directories/code-search/), or [avcodes.co.uk](https://www.avcodes.co.uk/airlcodesearch.asp)).
|
|
27
|
-
|
|
28
|
-
## Commit authorship
|
|
29
|
-
|
|
30
|
-
Commits should be authored as the repo owner: `Nissan Pow <nissan.pow@gmail.com>`.
|
|
26
|
+
Before implementing a reported data correction, verify the claim against at least one authoritative source (e.g. [airhex.com](https://airhex.com), [IATA code search](https://www.iata.org/en/publications/directories/code-search/), or [avcodes.co.uk](https://www.avcodes.co.uk/airlcodesearch.asp)).
|
package/airlines.dat
CHANGED
|
@@ -409,7 +409,7 @@
|
|
|
409
409
|
408,Avia Air N.V.,\N,,ARB,AVIAIR,Aruba,N
|
|
410
410
|
409,Air Routing International Corp.,\N,,ARC,,United States,N
|
|
411
411
|
410,Aerocondor,\N,2B,ARD,AEROCONDOR,Portugal,Y
|
|
412
|
-
411,
|
|
412
|
+
411,LATAM Airlines Colombia,\N,4C,ARE,LAN COLOMBIA,Colombia,Y
|
|
413
413
|
412,Aerolineas Argentinas,\N,AR,ARG,ARGENTINA,Argentina,Y
|
|
414
414
|
413,Arrowhead Airways,\N,,ARH,ARROWHEAD,United States,N
|
|
415
415
|
414,Aero Vics,\N,,ARI,AEROVICS,Mexico,N
|
|
@@ -1032,7 +1032,7 @@
|
|
|
1032
1032
|
1031,Aerolineas Mexicanas J S,\N,,LMX,LINEAS MEXICANAS,Mexico,N
|
|
1033
1033
|
1032,Air Almaty,\N,,LMY,AGLEB,Kazakhstan,N
|
|
1034
1034
|
1033,Air Almaty ZK,\N,,LMZ,ALUNK,Kazakhstan,N
|
|
1035
|
-
1034,
|
|
1035
|
+
1034,LATAM Airlines Ecuador,\N,XL,LNE,LAN ECUADOR,Ecuador,Y
|
|
1036
1036
|
1035,Airlink,\N,,LNK,LINK,South Africa,N
|
|
1037
1037
|
1036,Aerolineas Internacionales,\N,,LNT,LINEAINT,Mexico,N
|
|
1038
1038
|
1037,Alok Air,\N,,LOK,ALOK AIR,Sudan,N
|
|
@@ -3196,12 +3196,12 @@
|
|
|
3196
3196
|
3197,LACSA,\N,LR,LRC,LACSA,Costa Rica,Y
|
|
3197
3197
|
3198,LADE - Lineas Aereas Del Estado,\N,,LDE,LADE,Argentina,N
|
|
3198
3198
|
3199,LAI - Linea Aerea IAACA,\N,KG,BNX,AIR BARINAS,Venezuela,N
|
|
3199
|
-
3200,
|
|
3200
|
-
3201,
|
|
3199
|
+
3200,LATAM Airlines,\N,LA,LAN,LAN,Chile,Y
|
|
3200
|
+
3201,LATAM Airlines Argentina,\N,4M,DSM,LAN AR,Argentina,N
|
|
3201
3201
|
3202,LAN Cargo,\N,,LCO,LAN CARGO,Chile,N
|
|
3202
3202
|
3203,LAN Dominica,\N,,LNC,LANCANA,Dominican Republic,N
|
|
3203
|
-
3204,
|
|
3204
|
-
3205,
|
|
3203
|
+
3204,LATAM Airlines Chile,\N,LU,LXP,LANEX,Chile,Y
|
|
3204
|
+
3205,LATAM Airlines Peru,\N,LP,LPE,LANPERU,Peru,Y
|
|
3205
3205
|
3206,LANSA,\N,,LSA,INTERNACIONAL,Dominican Republic,N
|
|
3206
3206
|
3207,LAP Colombia - Lineas Aereas Petroleras,\N,,APT,S.A.,LAP,N
|
|
3207
3207
|
3208,LASTP,\N,,OTN,LASTP,S,N
|
|
@@ -4855,7 +4855,7 @@
|
|
|
4855
4855
|
4864,Trans International Express Aviation,\N,,BAP,BIG APPLE,United States,N
|
|
4856
4856
|
4865,TAG Aviation USA,\N,,TAG,TAG U-S,United States,N
|
|
4857
4857
|
4866,Talair,\N,,TAL,TALAIR,Papua New Guinea,N
|
|
4858
|
-
4867,
|
|
4858
|
+
4867,LATAM Airlines Brasil,\N,JJ,TAM,TAM,Brazil,Y
|
|
4859
4859
|
4868,Transaustralian Air Express,\N,,AUC,AUSCARGO,Australia,N
|
|
4860
4860
|
4869,TAP Portugal,TAP Air Portugal,TP,TAP,AIR PORTUGAL,Portugal,Y
|
|
4861
4861
|
4870,Tunisair,\N,TU,TAR,TUNAIR,Tunisia,Y
|
|
@@ -5144,7 +5144,7 @@
|
|
|
5144
5144
|
5153,Transcontinental Airlines,\N,,KRA,REGATA,Kazakhstan,N
|
|
5145
5145
|
5154,Transaviabaltika,\N,,KTB,TRANSBALTIKA,Lithuania,N
|
|
5146
5146
|
5155,Transair-Gyraintiee,\N,,KTS,KOTAIR,Russia,N
|
|
5147
|
-
5156,
|
|
5147
|
+
5156,LATAM Airlines Paraguay,\N,PZ,LAP,PARAGUAYA,Paraguay,Y
|
|
5148
5148
|
5157,The Lancair Company,\N,,LCC,LANCAIR,United States,N
|
|
5149
5149
|
5158,The Army Aviation Heritage Foundation,\N,,LEG,LEGACY,United States,N
|
|
5150
5150
|
5159,Top Sky International,\N,,LKW,TOPINTER,Indonesia,N
|
package/airlines.json
CHANGED
|
@@ -165,7 +165,7 @@
|
|
|
165
165
|
,
|
|
166
166
|
{"id":"410","name":"Aerocondor","alias":"\\N","iata":"2B","icao":"ARD","callsign":"AEROCONDOR","country":"Portugal","active":"Y"}
|
|
167
167
|
,
|
|
168
|
-
{"id":"411","name":"
|
|
168
|
+
{"id":"411","name":"LATAM Airlines Colombia","alias":"\\N","iata":"4C","icao":"ARE","callsign":"LAN COLOMBIA","country":"Colombia","active":"Y"}
|
|
169
169
|
,
|
|
170
170
|
{"id":"412","name":"Aerolineas Argentinas","alias":"\\N","iata":"AR","icao":"ARG","callsign":"ARGENTINA","country":"Argentina","active":"Y"}
|
|
171
171
|
,
|
|
@@ -303,7 +303,7 @@
|
|
|
303
303
|
,
|
|
304
304
|
{"id":"1017","name":"Air Alfa","alias":"\\N","iata":"","icao":"LFA","callsign":"","country":"Turkey","active":"Y"}
|
|
305
305
|
,
|
|
306
|
-
{"id":"1034","name":"
|
|
306
|
+
{"id":"1034","name":"LATAM Airlines Ecuador","alias":"\\N","iata":"XL","icao":"LNE","callsign":"LAN ECUADOR","country":"Ecuador","active":"Y"}
|
|
307
307
|
,
|
|
308
308
|
{"id":"1048","name":"Atlantis European Airways","alias":"\\N","iata":"TD","icao":"LUR","callsign":"","country":"Armenia","active":"Y"}
|
|
309
309
|
,
|
|
@@ -837,13 +837,11 @@
|
|
|
837
837
|
,
|
|
838
838
|
{"id":"3197","name":"LACSA","alias":"\\N","iata":"LR","icao":"LRC","callsign":"LACSA","country":"Costa Rica","active":"Y"}
|
|
839
839
|
,
|
|
840
|
-
{"id":"3200","name":"
|
|
840
|
+
{"id":"3200","name":"LATAM Airlines","alias":"\\N","iata":"LA","icao":"LAN","callsign":"LAN","country":"Chile","active":"Y"}
|
|
841
841
|
,
|
|
842
|
-
{"id":"
|
|
842
|
+
{"id":"3204","name":"LATAM Airlines Chile","alias":"\\N","iata":"LU","icao":"LXP","callsign":"LANEX","country":"Chile","active":"Y"}
|
|
843
843
|
,
|
|
844
|
-
{"id":"
|
|
845
|
-
,
|
|
846
|
-
{"id":"3205","name":"LAN Peru","alias":"\\N","iata":"LP","icao":"LPE","callsign":"LANPERU","country":"Peru","active":"Y"}
|
|
844
|
+
{"id":"3205","name":"LATAM Airlines Peru","alias":"\\N","iata":"LP","icao":"LPE","callsign":"LANPERU","country":"Peru","active":"Y"}
|
|
847
845
|
,
|
|
848
846
|
{"id":"3210","name":"LOT Polish Airlines","alias":"\\N","iata":"LO","icao":"LOT","callsign":"POLLOT","country":"Poland","active":"Y"}
|
|
849
847
|
,
|
|
@@ -1235,7 +1233,7 @@
|
|
|
1235
1233
|
,
|
|
1236
1234
|
{"id":"4863","name":"TAME","alias":"\\N","iata":"EQ","icao":"TAE","callsign":"TAME","country":"Ecuador","active":"Y"}
|
|
1237
1235
|
,
|
|
1238
|
-
{"id":"4867","name":"
|
|
1236
|
+
{"id":"4867","name":"LATAM Airlines Brasil","alias":"\\N","iata":"JJ","icao":"TAM","callsign":"TAM","country":"Brazil","active":"Y"}
|
|
1239
1237
|
,
|
|
1240
1238
|
{"id":"4869","name":"TAP Portugal","alias":"TAP Air Portugal","iata":"TP","icao":"TAP","callsign":"AIR PORTUGAL","country":"Portugal","active":"Y"}
|
|
1241
1239
|
,
|
|
@@ -1295,7 +1293,7 @@
|
|
|
1295
1293
|
,
|
|
1296
1294
|
{"id":"5146","name":"Turkish Air Force","alias":"\\N","iata":"","icao":"HVK","callsign":"TURKISH AIRFORCE","country":"Turkey","active":"Y"}
|
|
1297
1295
|
,
|
|
1298
|
-
{"id":"5156","name":"
|
|
1296
|
+
{"id":"5156","name":"LATAM Airlines Paraguay","alias":"\\N","iata":"PZ","icao":"LAP","callsign":"PARAGUAYA","country":"Paraguay","active":"Y"}
|
|
1299
1297
|
,
|
|
1300
1298
|
{"id":"5160","name":"Trans States Airlines","alias":"\\N","iata":"AX","icao":"LOF","callsign":"WATERSKI","country":"United States","active":"Y"}
|
|
1301
1299
|
,
|
|
@@ -7995,6 +7993,8 @@
|
|
|
7995
7993
|
,
|
|
7996
7994
|
{"id":"3199","name":"LAI - Linea Aerea IAACA","alias":"\\N","iata":"KG","icao":"BNX","callsign":"AIR BARINAS","country":"Venezuela","active":"N"}
|
|
7997
7995
|
,
|
|
7996
|
+
{"id":"3201","name":"LATAM Airlines Argentina","alias":"\\N","iata":"4M","icao":"DSM","callsign":"LAN AR","country":"Argentina","active":"N"}
|
|
7997
|
+
,
|
|
7998
7998
|
{"id":"3202","name":"LAN Cargo","alias":"\\N","iata":"","icao":"LCO","callsign":"LAN CARGO","country":"Chile","active":"N"}
|
|
7999
7999
|
,
|
|
8000
8000
|
{"id":"3203","name":"LAN Dominica","alias":"\\N","iata":"","icao":"LNC","callsign":"LANCANA","country":"Dominican Republic","active":"N"}
|
package/normalize.js
CHANGED
|
@@ -81,6 +81,15 @@ var ID_CORRECTIONS = {
|
|
|
81
81
|
'19849': { iata: 'GX' }, // Guangxi Beibu Gulf Airlines - correct code is GX not UQ
|
|
82
82
|
// Outdated airline assignments (upstream OpenFlights not yet updated):
|
|
83
83
|
'4239': { name: 'Volaris El Salvador', iata: 'N3', callsign: 'VOLSAL', country: 'El Salvador', active: 'Y' }, // VOS reassigned from Rovos Air (South Africa) to Volaris El Salvador
|
|
84
|
+
// LAN / TAM rebranding to LATAM:
|
|
85
|
+
'411': { name: 'LATAM Airlines Colombia', callsign: 'LAN COLOMBIA', country: 'Colombia' }, // Aires rebranded to LATAM Colombia; fix corrupted callsign and country " S.A."
|
|
86
|
+
'1034': { name: 'LATAM Airlines Ecuador' }, // Aerolane rebranded to LATAM Airlines Ecuador
|
|
87
|
+
'3200': { name: 'LATAM Airlines' }, // LAN Airlines rebranded to LATAM Airlines
|
|
88
|
+
'3201': { name: 'LATAM Airlines Argentina', active: 'N' }, // LAN Argentina rebranded to LATAM Airlines Argentina; ceased operations 2020
|
|
89
|
+
'3204': { name: 'LATAM Airlines Chile' }, // LAN Express rebranded to LATAM Airlines Chile
|
|
90
|
+
'3205': { name: 'LATAM Airlines Peru' }, // LAN Peru rebranded to LATAM Airlines Peru
|
|
91
|
+
'4867': { name: 'LATAM Airlines Brasil' }, // TAM Brazilian Airlines rebranded to LATAM Airlines Brasil
|
|
92
|
+
'5156': { name: 'LATAM Airlines Paraguay' }, // TAM Mercosur rebranded to LATAM Airlines Paraguay
|
|
84
93
|
};
|
|
85
94
|
|
|
86
95
|
var columns = ['id', 'name', 'alias', 'iata', 'icao', 'callsign', 'country', 'active'];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "airline-codes",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.6",
|
|
4
4
|
"description": "Airline codes (IATA) and information pulled from OpenFlights.org.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"JSONStream": "^1.0.4",
|
|
31
31
|
"backbone": "^1.1.2",
|
|
32
|
-
"csv": "^
|
|
32
|
+
"csv": "^6.6.3",
|
|
33
33
|
"lodash": "^4.17.21"
|
|
34
34
|
}
|
|
35
35
|
}
|