Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: remove Lerna #1229

Merged
merged 1 commit into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
338 changes: 0 additions & 338 deletions .deps/dev.md

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .deps/prod.md
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,7 @@
| [`[email protected]`](git://github.com/evangelion1204/multi-ini.git) | MIT | clearlydefined |
| `[email protected]` | MIT | #7571 |
| `[email protected]` | MIT | clearlydefined |
| [`[email protected]`](https://github.com/bitinn/node-fetch.git) | MIT | #10509 |
| [`[email protected]`](git://github.com/nodejs/node-gyp.git) | MIT | #15698 |
| [`[email protected]`](https://github.com/npm/nopt.git) | ISC | #9086 |
| [`[email protected]`](https://github.com/mikeal/oauth-sign) | Apache-2.0 | clearlydefined |
Expand Down
2 changes: 1 addition & 1 deletion build/dockerfiles/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ RUN if ! [ type "yarn" &> /dev/null ]; then \

COPY package.json /dashboard/
COPY yarn.lock /dashboard/
COPY lerna.json /dashboard/
COPY tsconfig.json /dashboard/
COPY run/wrksps.sh /dashboard/run/

ENV COMMON=packages/common
COPY ${COMMON}/package.json /dashboard/${COMMON}/
Expand Down
3 changes: 0 additions & 3 deletions build/dockerfiles/brew.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ RUN ln -s "$REMOTE_SOURCES_DIR"/devspaces-images-dashboard/app/devspaces-dashboa
# see https://source.redhat.com/groups/public/container-build-system/container_build_system_wiki/containers_from_source_multistage_builds_in_osbs#jive_content_id_Cachito_Integration_for_yarn
RUN yarn config set nodedir /usr; yarn config set unsafe-perm true && yarn install

# cachito:yarn step 4: lerna installed to $REMOTE_SOURCES_DIR/devspaces-images-dashboard/app/devspaces-dashboard/node_modules/.bin/lerna - add to path
RUN ln -s "$REMOTE_SOURCES_DIR"/devspaces-images-dashboard/app/devspaces-dashboard/node_modules/.bin/lerna /usr/local/bin/lerna

# cachito:yarn step 5: the actual build!
# hadolint ignore=DL3059
RUN yarn build
Expand Down
9 changes: 0 additions & 9 deletions lerna.json

This file was deleted.

8 changes: 5 additions & 3 deletions make-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,11 @@ function update_pkgs_versions() {
local VER=$1
# update root `package.json` version
npm --no-git-tag-version version --allow-same-version "${VER}"
# update each package version
yarn install --frozen-lockfile --no-immutable
npx lerna version --no-git-tag-version -y "${VER}"
# update packages versions
sed_in_place -e "s/\"version\": \".*\"/\"version\": \"${VER}\"/" package.json
sed_in_place -e "s/\"version\": \".*\"/\"version\": \"${VER}\"/" packages/dashboard-backend/package.json
sed_in_place -e "s/\"version\": \".*\"/\"version\": \"${VER}\"/" packages/dashboard-frontend/package.json
sed_in_place -e "s/\"version\": \".*\"/\"version\": \"${VER}\"/" packages/common/package.json
if [[ ${VER} != *"-next" ]]; then
# update devworkspace generator version for release
jq ".\"dependencies\".\"@eclipse-che/che-devworkspace-generator\" = \"${VER}\"" packages/dashboard-backend/package.json > packages/dashboard-backend/package.json.update
Expand Down
36 changes: 16 additions & 20 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,28 +19,24 @@
},
"license": "EPL-2.0",
"scripts": {
"build": "yarn prebuild && lerna run build --scope=@eclipse-che/dashboard-\\* --concurrency 1",
"build:dev": "yarn prebuild && lerna run build:dev --scope=@eclipse-che/dashboard-\\*",
"prebuild": "lerna run build --scope=@eclipse-che/common",
"prebuild:dev": "yarn prebuild",
"build": "yarn wrksps build",
"build:dev": "yarn wrksps build:dev",
"frontend:start": "yarn workspace @eclipse-che/dashboard-frontend start",
"start": "${PWD}/run/local-run.sh $@",
"start:prepare": "${PWD}/run/prepare-local-run.sh",
"start:cleanup": "${PWD}/run/revert-local-run.sh",
"license:check": "${PWD}/scripts/container_tool.sh run --rm -t -v ${PWD}/:/workspace/project quay.io/che-incubator/dash-licenses:next --check",
"license:generate": "${PWD}/scripts/container_tool.sh run --rm -t -v ${PWD}/:/workspace/project quay.io/che-incubator/dash-licenses:next",
"test": "yarn run pretest && lerna run test --stream -- --no-cache $@",
"start": "$PWD/run/local-run.sh $@",
"start:prepare": "$PWD/run/prepare-local-run.sh",
"start:cleanup": "$PWD/run/revert-local-run.sh",
"license:check": "$PWD/scripts/container_tool.sh run --rm -t -v $PWD/:/workspace/project quay.io/che-incubator/dash-licenses:next --check",
"license:generate": "$PWD/scripts/container_tool.sh run --rm -t -v $PWD/:/workspace/project quay.io/che-incubator/dash-licenses:next",
"test": "yarn run pretest && yarn wrksps test --no-cache",
"test:check": "yarn run pretest && yarn workspace @eclipse-che/dashboard-frontend test --config=jest.config.check.js",
"pretest": "yarn run prebuild",
"test:coverage": "yarn run test -- --coverage",
"format:check": "lerna run format:check",
"format:fix": "lerna run --stream format:fix",
"lint:check": "lerna run lint:check",
"lint:fix": "lerna run --stream lint:fix",
"patch": "${PWD}/run/patch.sh $@"
},
"devDependencies": {
"lerna": "^6"
"pretest": "yarn workspace @eclipse-che/common run build",
"test:coverage": "yarn run pretest && yarn wrksps test --coverage",
"format:check": "yarn wrksps format:check",
"format:fix": "yarn wrksps format:fix",
"lint:check": "yarn wrksps lint:check",
"lint:fix": "yarn wrksps lint:fix",
"patch": "$PWD/run/patch.sh $@",
"wrksps": "$PWD/run/wrksps.sh $*"
},
"resolutions": {
"@adobe/css-tools": "^4.3.2",
Expand Down
18 changes: 18 additions & 0 deletions run/wrksps.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/sh
#
# Copyright (c) 2021-2024 Red Hat, Inc.
# This program and the accompanying materials are made
# available under the terms of the Eclipse Public License 2.0
# which is available at https://www.eclipse.org/legal/epl-2.0/
#
# SPDX-License-Identifier: EPL-2.0
#

# The script is used to backward compatibility between yarn3 and yarn1 package managers.
# It will be removed with yarn1 support.

set -e

yarn workspace @eclipse-che/common "$@"
yarn workspace @eclipse-che/dashboard-frontend "$@"
yarn workspace @eclipse-che/dashboard-backend "$@"
2 changes: 1 addition & 1 deletion scripts/container_tool.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh
#
# Copyright (c) 2021-2024 Red Hat, Inc.
# This program and the accompanying materials are made
Expand Down
2 changes: 1 addition & 1 deletion scripts/sed_in_place.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh
#
# Copyright (c) 2021-2024 Red Hat, Inc.
# This program and the accompanying materials are made
Expand Down
Loading
Loading