diff options
author | Claire <claire.github-309c@sitedethib.com> | 2023-04-08 14:11:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-08 14:11:40 +0200 |
commit | 10469a0b857907f9fef0ed68b4ec5233895d8057 (patch) | |
tree | c9de2af7112dcf4c6e0f744d946eeecc3bc8d5bc | |
parent | dc6befe1a488adb76dd8c7c682a806b99cd16004 (diff) |
Move locale-data back to `app/javascript/mastodon/locales/locale-data` (#2169)
This reduces differences with upstream and fixes a bunch of locale-data files having been forgotten.
-rw-r--r-- | app/javascript/mastodon/locales/locale-data/README.md (renamed from app/javascript/locales/locale-data/README.md) | 0 | ||||
-rw-r--r-- | app/javascript/mastodon/locales/locale-data/oc.js (renamed from app/javascript/locales/locale-data/oc.js) | 0 | ||||
-rw-r--r-- | config/webpack/generateLocalePacks.js | 8 |
3 files changed, 4 insertions, 4 deletions
diff --git a/app/javascript/locales/locale-data/README.md b/app/javascript/mastodon/locales/locale-data/README.md index 83368fae7..83368fae7 100644 --- a/app/javascript/locales/locale-data/README.md +++ b/app/javascript/mastodon/locales/locale-data/README.md diff --git a/app/javascript/locales/locale-data/oc.js b/app/javascript/mastodon/locales/locale-data/oc.js index d4adc42eb..d4adc42eb 100644 --- a/app/javascript/locales/locale-data/oc.js +++ b/app/javascript/mastodon/locales/locale-data/oc.js diff --git a/config/webpack/generateLocalePacks.js b/config/webpack/generateLocalePacks.js index b1b818159..fedf0c7a1 100644 --- a/config/webpack/generateLocalePacks.js +++ b/config/webpack/generateLocalePacks.js @@ -13,7 +13,7 @@ const { existsSync, readdirSync, writeFileSync } = require('fs'); const { join, resolve } = require('path'); const rimraf = require('rimraf'); const mkdirp = require('mkdirp'); -const { flavours } = require('./configuration.js'); +const { flavours } = require('./configuration'); module.exports = Object.keys(flavours).reduce(function (map, entry) { const flavour = flavours[entry]; @@ -43,13 +43,13 @@ module.exports = Object.keys(flavours).reduce(function (map, entry) { // first try react-intl `node_modules/react-intl/locale-data/${baseLocale}.js`, // then check locales/locale-data - `app/javascript/locales/locale-data/${baseLocale}.js`, + `app/javascript/mastodon/locales/locale-data/${baseLocale}.js`, // fall back to English (this is what react-intl does anyway) 'node_modules/react-intl/locale-data/en.js', ].filter( - filename => existsSync(filename) + filename => existsSync(filename), ).map( - filename => filename.replace(/(?:node_modules|app\/javascript)\//, '') + filename => filename.replace(/(?:node_modules|app\/javascript)\//, ''), )[0]; const localeContent = `// // locales/${entry}/${locale}.js |