Merge pull request #4892 from owncloud/pnpm-2

[full-ci] Build idp and settings frontends with pnpm
This commit is contained in:
Benedikt Kulmann
2022-10-27 10:35:12 +02:00
committed by GitHub
27 changed files with 22001 additions and 25959 deletions
+1 -17
View File
@@ -1,17 +1 @@
# yarn2 with Zero-Installs: https://yarnpkg.com/features/zero-installs
#.yarn/*
#!.yarn/cache
#!.yarn/patches
#!.yarn/plugins
#!.yarn/releases
#!.yarn/sdks
#!.yarn/versions
# yarn2 not using Zero-Installs: https://yarnpkg.com/features/zero-installs
.yarn/*
!.yarn/patches
!.yarn/releases
!.yarn/plugins
!.yarn/sdks
!.yarn/versions
.pnp.*
.pnpm-store/
+2
View File
@@ -0,0 +1,2 @@
auto-install-peers=true
public-hoist-pattern[]=*
File diff suppressed because one or more lines are too long
-6
View File
@@ -1,6 +0,0 @@
nodeLinker: node-modules
yarnPath: .yarn/releases/yarn-3.1.0.cjs
enableScripts: false
enableTelemetry: false
+10 -10
View File
@@ -30,7 +30,7 @@ ci-go-generate: # CI runs ci-node-generate automatically before this target
ci-node-generate: assets
.PHONY: assets
assets: yarn-build \
assets: pnpm-build \
assets/identifier/static \
assets/identifier/static/logo.svg \
assets/identifier/static/favicon.ico
@@ -50,22 +50,22 @@ FAVICON_URL = https://raw.githubusercontent.com/owncloud/assets/main/favicon.ico
assets/identifier/static/favicon.ico:
curl --fail -o assets/identifier/static/favicon.ico ${FAVICON_URL}
.PHONY: yarn-build
yarn-build: node_modules
#yarn lint #TODO: activate
#yarn test #TODO: activate
yarn build
.PHONY: pnpm-build
pnpm-build: node_modules
#pnpm lint #TODO: activate
#pnpm test #TODO: activate
pnpm build
.PHONY: node_modules
node_modules:
yarn install --immutable
pnpm install
############ licenses ############
.PHONY: ci-node-check-licenses
ci-node-check-licenses: node_modules
yarn licenses:check
pnpm licenses:check
.PHONY: ci-node-save-licenses
ci-node-save-licenses: node_modules
yarn licenses:csv
yarn licenses:save
pnpm licenses:csv
pnpm licenses:save
+6 -6
View File
@@ -1,6 +1,6 @@
# Tools
YARN ?= yarn
PNPM ?= pnpm
MSGCAT ?= msgcat
MSGMERGE ?= msgmerge
MSGFMT ?= msgfmt
@@ -19,12 +19,12 @@ build: json
json:
@for po in $(POS); do \
lang=$$(echo $$po | sed "s/\.po//"); \
$(YARN) i18next-conv -K --skipUntranslated -l $$lang -s ../i18n/$$po -t ../src/locales/$$lang/translation.json; \
$(PNPM) i18next-conv -K --skipUntranslated -l $$lang -s i18n/$$po -t ../src/locales/$$lang/translation.json; \
done
$(YARN) node ../i18n/build-json.js ../src/locales/locales.json $(POS)
$(PNPM) node i18n/build-json.js ../src/locales/locales.json $(POS)
dev-translation.json: FORCE
$(YARN) i18next --fail-on-warnings
$(PNPM) i18next --fail-on-warnings
.PHONY: extract
extract: pot
@@ -34,8 +34,8 @@ pot: dev-translation.json
@tmpfile1=$(shell mktemp).po; \
tmpfile2=$(shell mktemp).po; \
trap 'rm -f "$$tmpfile1" "$$tmpfile2"' EXIT; \
$(YARN) i18next-conv --project "LibreGraph Connect Identifier" -K -l en -s i18n/dev-translation.json -t $$tmpfile1; \
$(YARN) node i18n/build-pot.js $$tmpfile1 $$tmpfile2; \
$(PNPM) i18next-conv --project "LibreGraph Connect Identifier" -K -l en -s i18n/dev-translation.json -t $$tmpfile1; \
$(PNPM) node i18n/build-pot.js $$tmpfile1 $$tmpfile2; \
$(MSGCAT) --no-wrap -o $(POT) $$tmpfile2
.PHONY: merge
+12312
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -30,7 +30,7 @@ const printBuildError = require('react-dev-utils/printBuildError');
const measureFileSizesBeforeBuild =
FileSizeReporter.measureFileSizesBeforeBuild;
const printFileSizesAfterBuild = FileSizeReporter.printFileSizesAfterBuild;
const useYarn = fs.existsSync(paths.yarnLockFile);
const usePnpm = fs.existsSync(paths.pnpmLockFile);
// These sizes are pretty large. We'll warn for bundles exceeding them.
const WARN_AFTER_BUNDLE_GZIP_SIZE = 512 * 1024;
@@ -102,7 +102,7 @@ checkBrowsers(paths.appPath, isInteractive)
publicUrl,
publicPath,
buildFolder,
useYarn
usePnpm
);
},
err => {
+2 -2
View File
@@ -32,7 +32,7 @@ const paths = require('../ui_config/paths');
const configFactory = require('../ui_config/webpack.config');
const createDevServerConfig = require('../ui_config/webpackDevServer.config');
const useYarn = fs.existsSync(paths.yarnLockFile);
const usePnpm = fs.existsSync(paths.pnpmLockFile);
const isInteractive = process.stdout.isTTY;
// Warn and crash if required files are missing
@@ -93,7 +93,7 @@ checkBrowsers(paths.appPath, isInteractive)
config,
devSocket,
urls,
useYarn,
usePnpm,
useTypeScript,
tscCompileOnError,
webpack,
+1 -1
View File
@@ -77,7 +77,7 @@ module.exports = {
appSrc: resolveApp('src'),
appTsConfig: resolveApp('tsconfig.json'),
appJsConfig: resolveApp('jsconfig.json'),
yarnLockFile: resolveApp('yarn.lock'),
pnpmLockFile: resolveApp('pnpm-lock.yaml'),
testsSetup: resolveModule(resolveApp, 'src/setupTests'),
proxySetup: resolveApp('src/setupProxy.js'),
appNodeModules: resolveApp('node_modules'),
-16009
View File
File diff suppressed because it is too large Load Diff