HEX
Server: Apache
System: Linux webd004.cluster130.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User: frenchy (106757)
PHP: 7.4.33
Disabled: _dyuweyrj4,_dyuweyrj4r,dl
Upload Files
File: /home/f/r/e/frenchy/www/french-american.org/current/node_modules/@allmarkedup/fang/support/build.js
#! /usr/bin/env node

'use strict';

const _       = require('lodash');
const fs      = require('fs');
const langMap = require('./languages');

const extToLang = {};

_.each(langMap, (lang, name) => {
    _.each(lang.extensions, ext => {
        extToLang[ext] = {
            name: name,
            mode: lang.ace_mode,
            scope: (lang.tm_scope && lang.tm_scope != 'none') ? lang.tm_scope : null,
            color: lang.color || null,
        };
    });
});

fs.writeFileSync('languages.json', JSON.stringify(extToLang, null, 2), 'UTF-8');